-
Notifications
You must be signed in to change notification settings - Fork 897
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
Improve create & edit playlist UX #5226
Changes from all commits
380e958
928544d
22cd16e
cc62f88
aa774c5
7472a95
81b1a37
8b95010
429f4e9
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,13 +15,24 @@ | |
:value="playlistName" | ||
:maxlength="255" | ||
class="playlistNameInput" | ||
@input="(input) => playlistName = input" | ||
@input="handlePlaylistNameInput" | ||
@click="createNewPlaylist" | ||
/> | ||
</ft-flex-box> | ||
<ft-flex-box v-if="playlistNameBlank"> | ||
<p> | ||
{{ $t('User Playlists.SinglePlaylistView.Toast["Playlist name cannot be empty. Please input a name."]') }} | ||
</p> | ||
</ft-flex-box> | ||
<ft-flex-box v-if="playlistWithNameExists"> | ||
<p> | ||
{{ $t('User Playlists.CreatePlaylistPrompt.Toast["There is already a playlist with this name. Please pick a different name."]') }} | ||
</p> | ||
</ft-flex-box> | ||
<ft-flex-box> | ||
<ft-button | ||
:label="$t('User Playlists.CreatePlaylistPrompt.Create')" | ||
:disabled="playlistPersistenceDisabled" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. thought/question: I have no idea how Vue knows to make the underlying button disabled when there doesn't seem to be a prop for this in our There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Vue calls that feature "fallthrough attributes", if the component doesn't have a prop for the attribute, it adds the attribute to the root/top-level HTML element inside that component. Vue 3 has an entire docs page on it, but it also describes Vue 3 specific behaviour so it's not that useful for us yet, Vue 2's docs only have an offhand mention of it (https://v2.vuejs.org/v2/api/#inheritAttrs). |
||
@click="createNewPlaylist" | ||
/> | ||
<ft-button | ||
|
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.
note: once the Vue 3 migration is complete, this will be a great place for composable functions.