-
Notifications
You must be signed in to change notification settings - Fork 11
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
collection backend #944
Merged
Merged
collection backend #944
Changes from 5 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
c475ccb
added collections in store. add backend methods and gtags
plumshum 3108134
added basic functionality for save course
plumshum 32add4c
fixed functionality for save courses to mutliple collections
plumshum 36f9925
finished backend and fixed frontend
plumshum 5d4df16
created editabilify for collection names
plumshum 726dbe3
fixed backend error and logic
plumshum File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,194 @@ | ||
@import '@/assets/scss/_variables.scss'; | ||
.saveCourseModal { | ||
&-title { | ||
display: flex; | ||
justify-content: space-between; | ||
padding-top: 0.6rem; | ||
gap: 0.5rem; | ||
img { | ||
margin-top: 2%; | ||
align-self: flex-start; | ||
} | ||
} | ||
|
||
&-header { | ||
display: flex; | ||
align-self: center; | ||
margin-bottom: 0.7rem; | ||
width: 112%; | ||
height: 2rem; | ||
border: 0.3px solid $lightGray; | ||
color: $primaryGray; | ||
padding: 1rem; | ||
|
||
&-text { | ||
display: flex; | ||
align-items: center; | ||
justify-content: space-between; | ||
font-size: 13px; | ||
font-weight: 900; | ||
width: 100%; | ||
|
||
&-addButton { | ||
cursor: pointer; | ||
&:hover { | ||
opacity: 0.5; | ||
} | ||
} | ||
} | ||
} | ||
|
||
&-body { | ||
display: flex; | ||
flex-direction: column; | ||
justify-content: flex-start; | ||
align-items: flex-start; | ||
color: $primaryGray; | ||
width: 100%; | ||
position: relative; | ||
max-height: 4.5rem; | ||
overflow-y: auto; | ||
overflow-x: hidden; | ||
box-sizing: border-box; | ||
|
||
::-webkit-scrollbar-button { | ||
display: none; // Hide the up and down arrows | ||
} | ||
|
||
&-content { | ||
display: flex; | ||
flex-direction: column; | ||
justify-content: center; | ||
align-items: flex-start; | ||
gap: 0.5rem; | ||
width: 100%; | ||
|
||
&.default-collection { | ||
justify-content: center; | ||
align-items: center; | ||
} | ||
|
||
&-collection { | ||
display: flex; | ||
flex-direction: row; | ||
justify-content: flex-start; | ||
align-items: center; | ||
color: $primaryGray; | ||
gap: 0.5rem; | ||
padding: 0rem; | ||
|
||
input[type='checkbox'] { | ||
margin: 0; | ||
padding: 0; | ||
appearance: none; | ||
width: 12px; | ||
height: 12px; | ||
border-radius: 10%; | ||
border: 1px solid $lightGray; | ||
background-color: white; | ||
cursor: pointer; | ||
position: relative; // For the ::before element positioning | ||
user-select: none; | ||
outline: none; | ||
|
||
&:hover { | ||
border: 1px solid $emGreen; | ||
} | ||
|
||
&:checked { | ||
background-color: $emGreen; | ||
border: 1px solid $emGreen; | ||
} | ||
|
||
// Show checkbox vector when checked | ||
&:checked::before { | ||
content: ''; | ||
background-image: url('@/assets/images/checkmark-color.svg'); | ||
background-size: contain; | ||
background-repeat: no-repeat; | ||
position: absolute; | ||
top: 50%; | ||
left: 50%; | ||
transform: translate(-48%, -38%); | ||
width: 9px; | ||
height: 9px; | ||
} | ||
} | ||
|
||
label { | ||
cursor: pointer; | ||
user-select: none; | ||
margin: 0; | ||
padding: 0; | ||
outline: none; | ||
} | ||
} | ||
} | ||
&-bottom { | ||
display: flex; | ||
align-items: center; | ||
justify-items: center; | ||
width: 100%; | ||
|
||
input[type='checkbox'] { | ||
margin-right: 0.35rem; | ||
appearance: none; | ||
width: 12px; | ||
height: 12px; | ||
border-radius: 10%; | ||
border: 1px solid $lightGray; | ||
background-color: white; | ||
cursor: pointer; | ||
position: relative; // For the ::before element positioning | ||
user-select: none; | ||
outline: none; | ||
|
||
&:hover { | ||
border: 1px solid $emGreen; | ||
} | ||
|
||
&:checked { | ||
background-color: $emGreen; | ||
border: 1px solid $emGreen; | ||
} | ||
|
||
// Show checkbox vector when checked | ||
&:checked::before { | ||
content: ''; | ||
background-image: url('@/assets/images/checkmark-color.svg'); | ||
background-size: contain; | ||
background-repeat: no-repeat; | ||
position: absolute; | ||
top: 50%; | ||
left: 50%; | ||
transform: translate(-48%, -38%); | ||
width: 9px; | ||
height: 9px; | ||
} | ||
} | ||
|
||
.new-collection-label { | ||
flex-grow: 1; | ||
display: flex; | ||
align-items: center; | ||
margin-top: 0.3rem; | ||
|
||
.editable-input { | ||
border: 1px solid $lightGray; | ||
border-radius: 4px; | ||
box-sizing: border-box; | ||
transition: border 0.2s ease; | ||
width: 80%; | ||
padding-left: 0.1rem; | ||
} | ||
} | ||
} | ||
} | ||
&-divider-line { | ||
display: flex; | ||
align-self: center; | ||
width: 112%; | ||
height: 0.3px; | ||
background-color: $lightGray; | ||
} | ||
} |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for adding these comments + details! your code is super clear - the add collection vs edit collection vs save course is very clearly divided. i know you're working on the merge right now but that should hopefully be pretty straightforward with your you divided all of the logic