-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Feature: Moving project solutions to Hotwire final tweaks #3956
Conversation
5aa2e97
to
4f06165
Compare
Because: * A few final touches before we start rolling this out to users. This commit: * Move the add solution button hook outside of the current users solution conditional - this is needed for the button to display correctly when the user deletes their solution after refreshing the page. * Change "Add submission" button text to "Add solution" - to fit the solutions title. * Add a hidden class to the drop down so it does not flash visible for a brief moment during re-render
4f06165
to
33de9f3
Compare
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.
Excited to see this start to get rolled out 🎉
@@ -24,7 +24,7 @@ | |||
data-transition-leave="transition ease-in duration-75" | |||
data-transition-leave-start="transform opacity-100 scale-100" | |||
data-transition-leave-end="transform opacity-10 scale-95" | |||
class="absolute right-0 z-10 mt-2 w-32 origin-top-right rounded-md bg-white dark:bg-gray-700 py-2 shadow-lg ring-1 ring-gray-900/5 dark:ring-gray-300/5 focus:outline-none" role="menu" aria-orientation="vertical" aria-labelledby="options-menu-0-button" tabindex="-1"> | |||
class="hidden absolute right-0 z-10 mt-2 w-32 origin-top-right rounded-md bg-white dark:bg-gray-700 py-2 shadow-lg ring-1 ring-gray-900/5 dark:ring-gray-300/5 focus:outline-none" role="menu" aria-orientation="vertical" aria-labelledby="options-menu-0-button" tabindex="-1"> |
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.
What controls the un-hiding of this element? Probably something obvious but it's not jumping out at me
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.
Good question and no worries, it's not that obvious. The visibility stimulus controller is unhiding via el-transistion. It toggles the hidden class and add transitions under the hood.
@@ -41,7 +41,7 @@ | |||
expect(page).to have_content(user.username) | |||
end | |||
|
|||
expect(page).not_to have_content('Add submission') | |||
expect(page).not_to have_content('Add solution') |
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.
Have made some comments on #3955 but not a blocker for this PR
Because:
This commit: