Skip to content
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

fix(NcListItem): Don't require name prop #6128

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
3 changes: 0 additions & 3 deletions l10n/messages.pot
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,6 @@ msgstr ""
msgid "Actions"
msgstr ""

msgid "Actions for item with name \"{name}\""
msgstr ""

msgid "Activities"
msgstr ""

Expand Down
11 changes: 3 additions & 8 deletions src/components/NcListItem/NcListItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -514,7 +514,7 @@ The `actions-icon` slot can be used to pass icon to the inner NcActions componen
<NcActions ref="actions"
:primary="isActive || active"
:force-menu="forceMenu"
:aria-label="computedActionsAriaLabel"
:aria-label="actionsAriaLabel"
@update:open="handleActionsUpdateOpen">
<template v-if="$slots['actions-icon']" #icon>
<!-- @slot Provide the custom icon for the right side quick menu -->
Expand All @@ -538,7 +538,6 @@ The `actions-icon` slot can be used to pass icon to the inner NcActions componen
import NcActions from '../NcActions/index.js'
import NcCounterBubble from '../NcCounterBubble/index.js'
import NcVNodes from '../NcVNodes/index.js'
import { t } from '../../l10n.js'

export default {
name: 'NcListItem',
Expand All @@ -563,7 +562,7 @@ export default {
*/
name: {
type: String,
required: true,
default: undefined,
},

/**
Expand Down Expand Up @@ -641,7 +640,7 @@ export default {
*/
actionsAriaLabel: {
type: String,
default: '',
required: true,
},

/**
Expand Down Expand Up @@ -724,10 +723,6 @@ export default {
return (this.details !== '' || this.hasDetails)
&& (!this.displayActionsOnHoverFocus || this.forceDisplayActions)
},

computedActionsAriaLabel() {
return this.actionsAriaLabel || t('Actions for item with name "{name}"', { name: this.name })
},
},

watch: {
Expand Down
Loading