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

Refactor/locales #432

Merged
merged 5 commits into from
Jul 6, 2023
Merged

Refactor/locales #432

merged 5 commits into from
Jul 6, 2023

Conversation

queuing4oranges
Copy link
Collaborator

  • replacing dynamic values in locales - in asab-webui

-- when locales is loaded normally:

Kazam_screencast_00000.mp4

-- when the locales file is corrupted:

Kazam_screencast_00001.mp4

@queuing4oranges queuing4oranges requested a review from Pe5h4 June 30, 2023 10:56
@queuing4oranges queuing4oranges self-assigned this Jun 30, 2023
Copy link
Collaborator

@Pe5h4 Pe5h4 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@queuing4oranges Ok, this looks good - dont forget to update also locales in demo app and add the changelog. Btw. the videos can be displayed because of corrupted content :)

@queuing4oranges
Copy link
Collaborator Author

replacing locales in asab-webui demo app

when locales load normally:

demo-locales-correct.mp4

when locales file is corrupted:

demo-locales-corrupted.mp4

hope the video works!

Copy link
Collaborator

@Pe5h4 Pe5h4 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@queuing4oranges Small change request

@@ -162,7 +162,8 @@ export default function ({ currentPage, setPage, lastPage, style }) {
</Dropdown>

<div className="mr-2">
{pages && (pages.length > 1) ? t('Pages', {pages: (lastPage == 0) ? 1 : lastPage}) : t('Page', {pages: (lastPage == 0) ? 1 : lastPage})}
{pages && (pages.length > 1) ? (`${t("of")} ${pages.length} ${t("Pages")}`) :
(`${t("of")} ${pages.length} ${t("Page")}`)}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@queuing4oranges Here I believe we want to have sometjing like:

{pages && (pages.length > 1) ? (`${t("of")} ${(lastPage == 0) ? 1 : lastPage} ${t("Pages")}`) : (`${t("of")} ${(lastPage == 0) ? 1 : lastPage} ${t("Page")}`)}

@Pe5h4 Pe5h4 self-requested a review July 5, 2023 17:10
Copy link
Collaborator

@Pe5h4 Pe5h4 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@queuing4oranges alright, this is good

@queuing4oranges queuing4oranges marked this pull request as ready for review July 6, 2023 09:13
@petrKavulok petrKavulok merged commit 06af558 into master Jul 6, 2023
@petrKavulok petrKavulok deleted the refactor/replace-dynamic-locales branch July 6, 2023 09:16
@queuing4oranges queuing4oranges restored the refactor/replace-dynamic-locales branch July 12, 2023 13:10
@ateska ateska deleted the refactor/replace-dynamic-locales branch August 8, 2023 09:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants