Skip to content

Add membership perks #168

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 29 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
d4e9a1a
Add leaderboard emoji to extension text
maxwofford Apr 16, 2025
2ffaa63
Add membership pages
maxwofford Apr 19, 2025
2a85cd1
Add in "member since" data
maxwofford Apr 19, 2025
7428ae4
Format member since in a fancy way
maxwofford Apr 19, 2025
a958d34
Add Preferred status levels and benefits section to memberships page
devenjadhav Apr 19, 2025
670caa9
Merge branch 'membership' of https://github.com/hackclub/harbor into …
devenjadhav Apr 19, 2025
c09e40e
Merge remote changes
devenjadhav Apr 19, 2025
05aa54e
Switch to using membership model
maxwofford Apr 19, 2025
a8adb8c
Fix miscommitted database config
maxwofford Apr 19, 2025
2128a09
Add random legal-sounding thingies
maxwofford Apr 19, 2025
3d46fc4
Bump bullet from 8.0.3 to 8.0.4 (#166)
dependabot[bot] Apr 19, 2025
eba1276
Move membership card to show page and enhance styling
devenjadhav Apr 19, 2025
a78fc00
Add premium card JS interactions and flag asset
devenjadhav Apr 19, 2025
fd1f258
Add membership status on membership
maxwofford Apr 19, 2025
2972b10
Simpler impersonation link colors
maxwofford Apr 19, 2025
d2e26f0
Cache leaderboard values
maxwofford Apr 19, 2025
55511d2
Update membership hours
maxwofford Apr 19, 2025
9d518c5
Move warehouse models down further in scope
maxwofford Apr 20, 2025
c23a970
Add program engagements from warehouse
maxwofford Apr 20, 2025
e13c184
Simplify membership route / make admin only
maxwofford Apr 20, 2025
899dbdc
Improve styling on membership page
maxwofford Apr 20, 2025
6e33734
Setup status stars
maxwofford Apr 20, 2025
b860518
Rounded status on membership index page
maxwofford Apr 20, 2025
189e772
Add in YSWS name for projects
maxwofford Apr 20, 2025
aa5dd03
Update membership page with new tier requirements and benefits
devenjadhav Apr 20, 2025
9775c30
Fix membership page styling and layout - Add membership classes and i…
devenjadhav Apr 20, 2025
397f0dd
Add membership enum to users
maxwofford Apr 21, 2025
c8a02e0
Better separation of concerns for membership logic
maxwofford Apr 21, 2025
ffd5162
Create membership upgrade requests in db
maxwofford Apr 22, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,11 @@ gem "flamegraph"

gem "skylight"

gem "airrecord"

# For activity logging
gem "public_activity"

group :development, :test do
# See https://guides.rubyonrails.org/debugging_rails_applications.html#debugging-with-the-debug-gem
gem "debug", platforms: %i[ mri windows ], require: "debug/prelude"
Expand Down
20 changes: 18 additions & 2 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,10 @@ GEM
uri (>= 0.13.1)
addressable (2.8.7)
public_suffix (>= 2.0.2, < 7.0)
airrecord (1.0.12)
faraday (>= 1.0, < 3.0)
faraday-net_http_persistent
net-http-persistent
ast (2.4.2)
avo (3.19.3)
actionview (>= 6.1)
Expand Down Expand Up @@ -108,7 +112,7 @@ GEM
brakeman (7.0.2)
racc
builder (3.3.0)
bullet (8.0.3)
bullet (8.0.4)
activesupport (>= 3.0.0)
uniform_notifier (~> 1.11)
capybara (3.40.0)
Expand All @@ -123,7 +127,7 @@ GEM
childprocess (5.1.0)
logger (~> 1.5)
concurrent-ruby (1.3.5)
connection_pool (2.5.0)
connection_pool (2.5.1)
crass (1.0.6)
date (3.4.1)
debug (1.10.0)
Expand Down Expand Up @@ -151,6 +155,9 @@ GEM
multipart-post (~> 2.0)
faraday-net_http (3.4.0)
net-http (>= 0.5.0)
faraday-net_http_persistent (2.3.0)
faraday (~> 2.5)
net-http-persistent (>= 4.0.4, < 5)
ffi (1.17.1-aarch64-linux-gnu)
ffi (1.17.1-aarch64-linux-musl)
ffi (1.17.1-arm-linux-gnu)
Expand Down Expand Up @@ -252,6 +259,8 @@ GEM
multipart-post (2.4.1)
net-http (0.6.0)
uri
net-http-persistent (4.0.5)
connection_pool (~> 2.2)
net-imap (0.5.6)
date
net-protocol
Expand Down Expand Up @@ -304,6 +313,11 @@ GEM
psych (5.2.3)
date
stringio
public_activity (3.0.1)
actionpack (>= 6.1.0)
activerecord (>= 6.1)
i18n (>= 0.5.0)
railties (>= 6.1.0)
public_suffix (6.0.1)
puma (6.6.0)
nio4r (~> 2.0)
Expand Down Expand Up @@ -491,6 +505,7 @@ PLATFORMS

DEPENDENCIES
activerecord-import
airrecord
avo (>= 3.2.1)
avo-record_link_field (~> 0.0.2)
bootsnap
Expand All @@ -511,6 +526,7 @@ DEPENDENCIES
paper_trail
pg
propshaft
public_activity
puma (>= 5.0)
query_count
rack-cors
Expand Down
79 changes: 68 additions & 11 deletions app/assets/stylesheets/application.css
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,21 @@

@import "https://uchu.style/color.css";
@import "https://cdn.jsdelivr.net/npm/@picocss/pico@2/css/pico.min.css";
@import "membership.css";

/* colors */

:root {
--muted-color: var(--uchu-gray);
--black: rgb(42, 42, 42);
--smoke: rgb(242, 242, 242);
/* color: var(--black); */
/* background-color: var(--smoke); */

/* Status colors */
--basic-color: #1fa0eb;
--bronze-color: #CD7F32;
--silver-color: #E8E8E8;
--gold-color: #FFD700;
--diamond-color: #B9F2FF;
}

:root.development {
Expand Down Expand Up @@ -295,19 +301,40 @@

.avatar-container {
position: relative;
cursor: pointer;
transition: transform 0.2s ease;
z-index: 1;
margin-left: -15px;
display: inline-block;
}

.avatar-container:first-child {
margin-left: 0;
.avatar-container .status-icon {
position: absolute;
bottom: -3px;
right: -3px;
width: 16px;
height: 16px;
margin: 0;
}

.avatar-container .status-icon.basic {
fill: var(--basic-color);
}

.avatar-container:hover {
transform: translateY(-3px);
z-index: 5;
.avatar-container .status-icon.bronze {
fill: var(--bronze-color);
}

.avatar-container .status-icon.silver {
fill: var(--silver-color);
}

.avatar-container .status-icon.gold {
fill: var(--gold-color);
}

.avatar-container .status-icon.diamond {
fill: var(--diamond-color);
}

.avatar-container:first-child {
margin-left: 0;
}

.setup-avatar {
Expand Down Expand Up @@ -477,3 +504,33 @@
code {
word-break: break-word;
}

/* Status icons in membership index */
.status-card .status-icon {
width: 24px;
height: 24px;
border-radius: 50%;
margin-bottom: 1rem;
border: 2px solid white;
box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.status-card .status-icon.basic {
background: var(--basic-color);
}

.status-card .status-icon.bronze {
background: var(--bronze-color);
}

.status-card .status-icon.silver {
background: var(--silver-color);
}

.status-card .status-icon.gold {
background: var(--gold-color);
}

.status-card .status-icon.diamond {
background: var(--diamond-color);
}
7 changes: 1 addition & 6 deletions app/assets/stylesheets/flash.css
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,7 @@ footer a:hover {
}

.impersonate-link {
color: #cc5555 !important;
font-weight: bold;
color: var(--primary-color) !important;
}

@media (prefers-color-scheme: dark) {
Expand All @@ -64,8 +63,4 @@ footer a:hover {
footer:hover {
color: rgba(220, 220, 220, 0.9);
}

.impersonate-link {
color: #ff9999 !important;
}
}
Loading
Loading