-
-
Notifications
You must be signed in to change notification settings - Fork 301
Update ESoCC strings after UX writing review #5819
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
base: unstable
Are you sure you want to change the base?
Changes from all commits
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 |
|---|---|---|
|
|
@@ -16,10 +16,10 @@ | |
| <component :is="showDraftMode ? 'KRadioButtonGroup' : 'div'"> | ||
| <KRadioButton | ||
| v-if="showDraftMode" | ||
| :label="modeLive$()" | ||
| :label="publishChannelMode$()" | ||
| :buttonValue="PublishModes.LIVE" | ||
| :currentValue="mode" | ||
| :description="modeLiveDescription$()" | ||
| :description="publishChannelDescription$()" | ||
|
Member
Author
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. renamed for clarity |
||
| @input="mode = PublishModes.LIVE" | ||
| /> | ||
|
|
||
|
|
@@ -53,7 +53,7 @@ | |
| showInvalidText | ||
| :label="versionDescriptionLabel$()" | ||
| :invalid="isVersionNotesBlurred && !isVersionNotesValid" | ||
| :invalidText="versionNotesRequiredMessage$()" | ||
| :invalidText="fieldRequired$()" | ||
| textArea | ||
| :maxlength="250" | ||
| :appearanceOverrides="{ maxWidth: 'none' }" | ||
|
|
@@ -70,7 +70,7 @@ | |
| v-model="newChannelLanguage" | ||
| :label="languageLabel$()" | ||
| :invalid="isLanguageSelectBlurred && !isNewLanguageValid" | ||
| :invalidText="languageRequiredMessage$()" | ||
| :invalidText="fieldRequired$()" | ||
| :options="languageOptions" | ||
| @blur="isLanguageSelectBlurred = true" | ||
| /> | ||
|
|
@@ -112,26 +112,17 @@ | |
| > | ||
| {{ incompleteResourcesDescription1$() }} | ||
| </div> | ||
| <div | ||
| class="warning-description" | ||
| :style="{ | ||
| color: $themePalette.grey.v_800, | ||
| marginTop: '16px', | ||
| }" | ||
| > | ||
| {{ incompleteResourcesDescription2$() }} | ||
| </div> | ||
|
Member
Author
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. removed as unnecessary |
||
| </div> | ||
| </div> | ||
| </div> | ||
| </div> | ||
|
|
||
| <KRadioButton | ||
| v-if="showDraftMode" | ||
| :label="modeDraft$()" | ||
| :label="publishDraftMode$()" | ||
| :buttonValue="PublishModes.DRAFT" | ||
| :currentValue="mode" | ||
| :description="modeDraftDescription$()" | ||
| :description="publishDraftDescription$()" | ||
| @input="mode = PublishModes.DRAFT" | ||
| /> | ||
| </component> | ||
|
|
@@ -166,6 +157,7 @@ | |
| import { Channel, CommunityLibrarySubmission } from 'shared/data/resources'; | ||
| import { forceServerSync } from 'shared/data/serverSync'; | ||
| import { communityChannelsStrings } from 'shared/strings/communityChannelsStrings'; | ||
| import commonStrings from 'shared/translator'; | ||
| import { LanguagesList } from 'shared/leUtils/Languages'; | ||
| import logging from 'shared/logging'; | ||
| import { FeatureFlagKeys } from 'shared/constants'; | ||
|
|
@@ -205,23 +197,22 @@ | |
| publishChannel$, | ||
| publishAction$, | ||
| saveDraft$, | ||
| modeLive$, | ||
| modeDraft$, | ||
| publishChannelMode$, | ||
| publishDraftMode$, | ||
| versionNotesLabel$, | ||
| modeLiveDescription$, | ||
| modeDraftDescription$, | ||
| publishChannelDescription$, | ||
| publishDraftDescription$, | ||
| publishingInfo$, | ||
| versionDescriptionLabel$, | ||
| incompleteResourcesWarning$, | ||
| incompleteResourcesDescription1$, | ||
| incompleteResourcesDescription2$, | ||
| cancelAction$, | ||
| languageLabel$, | ||
| languageRequiredMessage$, | ||
| draftBeingPublishedNotice$, | ||
| versionNotesRequiredMessage$, | ||
| } = communityChannelsStrings; | ||
|
|
||
| const { fieldRequired$ } = commonStrings; | ||
|
|
||
| const currentChannel = computed(() => store.getters['currentChannel/currentChannel']); | ||
| const getContentNode = computed(() => store.getters['contentNode/getContentNode']); | ||
| const areAllChangesSaved = computed(() => store.getters['areAllChangesSaved']); | ||
|
|
@@ -416,21 +407,19 @@ | |
| isVersionNotesValid, | ||
| submitText, | ||
|
|
||
| modeLive$, | ||
| modeDraft$, | ||
| publishChannelMode$, | ||
| publishDraftMode$, | ||
| publishChannel$, | ||
| versionNotesLabel$, | ||
| modeLiveDescription$, | ||
| modeDraftDescription$, | ||
| publishChannelDescription$, | ||
| publishDraftDescription$, | ||
| publishingInfo$, | ||
| versionDescriptionLabel$, | ||
| incompleteResourcesWarning$, | ||
| incompleteResourcesDescription1$, | ||
| incompleteResourcesDescription2$, | ||
| cancelAction$, | ||
| languageLabel$, | ||
| languageRequiredMessage$, | ||
| versionNotesRequiredMessage$, | ||
| fieldRequired$, | ||
|
|
||
| onClose, | ||
| submit, | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -30,7 +30,7 @@ jest.mock('shared/data/resources', () => ({ | |
|
|
||
| const store = factory(); | ||
|
|
||
| const { nonePrimaryInfo$, flaggedPrimaryInfo$, approvedPrimaryInfo$, submittedPrimaryInfo$ } = | ||
| const { nonePrimaryInfo$, needsChangesPrimaryInfo$, approvedPrimaryInfo$ } = | ||
| communityChannelsStrings; | ||
|
|
||
| async function makeWrapper({ channel, publishedData, latestSubmission }) { | ||
|
|
@@ -195,7 +195,7 @@ describe('SubmitToCommunityLibrarySidePanel', () => { | |
|
|
||
| const infoSection = wrapper.find('.info-section'); | ||
| expect(infoSection.exists()).toBe(true); | ||
| expect(infoSection.text()).toContain(flaggedPrimaryInfo$()); | ||
| expect(infoSection.text()).toContain(needsChangesPrimaryInfo$()); | ||
|
Member
Author
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. renamed the string as well for consistency |
||
| }); | ||
|
|
||
| it('when the previous submission was approved', async () => { | ||
|
|
@@ -219,7 +219,13 @@ describe('SubmitToCommunityLibrarySidePanel', () => { | |
|
|
||
| const infoSection = wrapper.find('.info-section'); | ||
| expect(infoSection.exists()).toBe(true); | ||
| expect(infoSection.text()).toContain(submittedPrimaryInfo$()); | ||
| // PENDING status shows no primary info text — only the status chip | ||
| const infoText = wrapper.find('.info-text'); | ||
| expect(infoText.text()).toBe(''); | ||
| // Chip uses <script setup> with CSS v-bind (Vue 3 feature), so its text content is not | ||
| // available via VTU v1. Verify the chip is rendered with the correct status instead. | ||
| const statusChip = wrapper.findComponent(CommunityLibraryStatusChip); | ||
| expect(statusChip.exists()).toBe(true); | ||
| }); | ||
| }); | ||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -175,7 +175,7 @@ | |
| v-model="description" | ||
| :disabled="!canBeEdited" | ||
| :invalid="description.length < 1" | ||
| :invalidText="descriptionRequired$()" | ||
| :invalidText="fieldRequired$()" | ||
| textArea | ||
| :label="descriptionLabel$()" | ||
| :maxlength="250" | ||
|
|
@@ -240,6 +240,7 @@ | |
| import { translateMetadataString } from 'shared/utils/metadataStringsTranslation'; | ||
| import countriesUtil from 'shared/utils/countries'; | ||
| import { communityChannelsStrings } from 'shared/strings/communityChannelsStrings'; | ||
| import commonStrings from 'shared/translator'; | ||
| import { CommunityLibrarySubmission } from 'shared/data/resources'; | ||
|
|
||
| import SidePanelModal from 'shared/views/SidePanelModal'; | ||
|
|
@@ -276,7 +277,6 @@ | |
| lessDetailsButton$, | ||
| countryLabel$, | ||
| descriptionLabel$, | ||
| descriptionRequired$, | ||
| notPublishedWarningTitle$, | ||
| notPublishedWarningDescription$, | ||
| publicWarningTitle$, | ||
|
|
@@ -285,9 +285,8 @@ | |
| alreadySubmittedWarningDescription$, | ||
| submitButton$, | ||
| cancelAction$, | ||
| submittedPrimaryInfo$, | ||
| approvedPrimaryInfo$, | ||
| flaggedPrimaryInfo$, | ||
| needsChangesPrimaryInfo$, | ||
| nonePrimaryInfo$, | ||
| channelVersion$, | ||
| submittedSnackbar$, | ||
|
|
@@ -297,6 +296,8 @@ | |
| confirmReplacementText$, | ||
| } = communityChannelsStrings; | ||
|
|
||
| const { fieldRequired$ } = commonStrings; | ||
|
|
||
| const annotationColor = computed(() => tokensTheme.annotation); | ||
| const infoTextColor = computed(() => paletteTheme.grey.v_700); | ||
|
|
||
|
|
@@ -343,17 +344,13 @@ | |
| if (!latestSubmissionIsFinished.value) return undefined; | ||
|
|
||
| switch (latestSubmissionStatus.value) { | ||
| case CommunityLibraryStatus.PENDING: | ||
|
Member
Author
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. removed as redundant |
||
| return { | ||
| primaryText: submittedPrimaryInfo$(), | ||
| }; | ||
| case CommunityLibraryStatus.APPROVED: | ||
| return { | ||
| primaryText: approvedPrimaryInfo$(), | ||
| }; | ||
| case CommunityLibraryStatus.REJECTED: | ||
| return { | ||
| primaryText: flaggedPrimaryInfo$(), | ||
| primaryText: needsChangesPrimaryInfo$(), | ||
| }; | ||
| case null: | ||
| return { | ||
|
|
@@ -572,7 +569,7 @@ | |
| lessDetailsButton$, | ||
| countryLabel$, | ||
| descriptionLabel$, | ||
| descriptionRequired$, | ||
| fieldRequired$, | ||
| channelVersion$, | ||
| notPublishedWarningTitle$, | ||
| notPublishedWarningDescription$, | ||
|
|
||
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.
these are admin-only so not translated, but I updated the langage here for consistency