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

feat(button): add built-in translations #5447

Conversation

anveshmekala
Copy link
Contributor

@anveshmekala anveshmekala commented Oct 11, 2022

Related Issue: #4961

Summary

This PR will add built-in translation support for calcite-button

@github-actions github-actions bot added the enhancement Issues tied to a new feature or request. label Oct 11, 2022
@anveshmekala anveshmekala marked this pull request as ready for review October 19, 2022 22:34
@anveshmekala anveshmekala requested a review from a team as a code owner October 19, 2022 22:34
@anveshmekala anveshmekala requested a review from jcfranco October 19, 2022 22:41
benelan and others added 14 commits October 20, 2022 13:53
#5528)

* ci(screener): renable screener on pushes to master to update baseline

* cleanup

Co-authored-by: Ben Elan <benelan@users.noreply.github.com>
…5519)

* fix: components should only react to primary pointer events.

* cleanup. add pointerdown

* fix test

* make sure primary?

* review fixes
…5488)

* feat(date-picker): add numberingSystem property

* docs(date-picker): cleanup lang/numberingSystem selection code

* feat(input-date-picker): add numberingSystem property [WIP]

* add stories

* cleanup

* fix spec test

* cleanup

* test(date-picker-day): fix failing disabled commonTest

* merge master

* cleanup

* review cleanups

* skip (de)localization when formatter is not initialized

* cleanup and add a spec test

* don't init formatter until necessary

* final cleanup

* replace stepped stories and change locale to lang

* test(input-date-picker): add dark theme class to darkThemeRTL story

Co-authored-by: Ben Elan <benelan@users.noreply.github.com>
* docs(card): defined thumbnailPosition and consistent api styling across component

* fix typo

* remove extraneous dash

* add backticks to comps

* add b + c component consistency

* edits

* doc feedback
…n non-Chromium browsers (#5542)

* fix: add custom code for floating-ui positioning across shadow DOM in non-Chrome browsers

* tidy up

* fix conditional to avoid setting up fix for non-browser environments

* provide a way to opt-out of fix in favor of performance
…5484)

* fix: fix jarring positioning when a closed component is first opened

* uncomment actual fix and switch story to be stepped

* tweak story to capture initial positioning

* fix typo

* add missing setAttr argument

* add delay before screenshot test setup

* revisit approach to preserve debounced internal repositioning calls and correct positioning

* drop unnecessary story

* tidy up

* fix hydrate build

* restore leading option

* update test

* tweak positioning

* drop scale transformto have correct dimensions initially
* reposition immediately on componentDidLoad

* update tests

* revert index.html updates

* use transitions to reset positioning

* fix test.

Co-authored-by: Matt Driscoll <mdriscoll@esri.com>
Elijbet and others added 8 commits October 24, 2022 18:14
…idden (#5537)

* fix(calcite-loader, calcite-input-message): drop active in favor of hidden

* changes applied to input-message

* modify render assertion in the tests

* remove redundant hidden prop along with documentation (global attribute)

* add the link to mdn hidden attribute
* feat(flow-item): Add scroll event. (#5546)

* add a test
ci: update need info url for a11y
…CN locale. (#5534)

fix(date-picker): display correct date format order in header for zh-CN locale
Copy link
Member

@jcfranco jcfranco left a comment

Choose a reason for hiding this comment

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

Other than a question regarding the use of Build.isBrowser and modified connectLabel call, this LGTM! 🎉

//--------------------------------------------------------------------------
//
// Lifecycle
//
//--------------------------------------------------------------------------

connectedCallback(): void {
async connectedCallback(): Promise<void> {
if (Build.isBrowser) {
Copy link
Member

Choose a reason for hiding this comment

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

Why do we need to check for isBrowser here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Invoke mutationObserver only in the browser context and avoid hydrate errors for prerender builds. This is an interesting case where this occurs only for a few components.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

it is resolved now. we longer need to check for build context at the component level.

src/components/button/button.tsx Outdated Show resolved Hide resolved
benelan and others added 9 commits October 26, 2022 11:24
* fix(stepper-item): set numberingSystem in render block

* cleanup

* cleanup the cleanup

Co-authored-by: Ben Elan <benelan@users.noreply.github.com>
…Element is clicked quickly (#5643)

* fix(tooltip): Stop hover event when closeOnClick is true and click occurs. (#5538)

* add test

* review cleanup
@anveshmekala anveshmekala changed the base branch from master to anveshmekala/4961-add-built-in-pseudo-translations October 26, 2022 21:59
@anveshmekala anveshmekala merged commit 7bc4c50 into anveshmekala/4961-add-built-in-pseudo-translations Oct 26, 2022
@anveshmekala anveshmekala deleted the anveshmekala/4961-button-add-built-in-translation-support branch October 26, 2022 22:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Issues tied to a new feature or request.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants