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(blade): tabs web implementation #1694

Merged
merged 27 commits into from
Oct 30, 2023
Merged

feat(blade): tabs web implementation #1694

merged 27 commits into from
Oct 30, 2023

Conversation

anuraghazra
Copy link
Member

@anuraghazra anuraghazra commented Oct 4, 2023

  • PR 1 - Web Implementation (this PR)
  • PR 2 - Native Implementation
  • PR 3 - Documentation

@changeset-bot
Copy link

changeset-bot bot commented Oct 4, 2023

🦋 Changeset detected

Latest commit: 689143a

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@razorpay/blade Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions
Copy link
Contributor

github-actions bot commented Oct 9, 2023

✅ PR title follows Conventional Commits specification.

saurabhdaware
saurabhdaware previously approved these changes Oct 26, 2023
* feat: initial rn tabs

* feat: refactor tabs implementation

* fix: bug with sceneMap

* chore: fix tabbar filled width bug

* chore: fix initial value, androidshadow, indicator spacing

* chore: minor

* feat: added divider in filled tabs rn

* chore: update rn with new design

* chore: pass lazy prop

* chore: review comments

* chore: add comment

* chore: fix rn context type issue

* test: added Tabs web & native test (#1743)

* chore: added web tests

* chore: update snaps

* test: added more web tests

* chore: native test wip

* chore: rn tests

* chore: minor update

* chore: add ssr test

* chore: remove comments

* docs(blade): added documentation for tabs (#1715)

* docs: added examples/docs for tabs

* fix: vertical border taking up 100% height

* chore: minor changes

* chore: fix rn stories

* docs: added product usecases

* chore: update docs for react router

* chore: added kitchen sink

* chore: remove todo

* chore: update styled props of tablist

* chore: wrap with card

* chore: prevent vertical on mobile

* chore: update spacing

* chore: export tabs

* chore: fix rn stories

* chore: add meta attributes

* chore: remove version change

* chore: update snaps
@github-actions
Copy link
Contributor

github-actions bot commented Oct 27, 2023

Image description CodeRabbit


Uplevel your code reviews with CodeRabbit Pro

CodeRabbit Pro

If you like this project, please support us by purchasing the Pro version. The Pro version has advanced context, superior noise reduction and several proprietary improvements compared to the open source version. Moreover, CodeRabbit Pro is free for open source projects.

@codesandbox-ci
Copy link

codesandbox-ci bot commented Oct 27, 2023

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 689143a:

Sandbox Source
razorpay/blade: basic Configuration

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Image description CodeRabbit

Commits Files that changed from the base of the PR and between d6f5210 and 8fbd3d8 commits.
Files selected (29)
  • .eslintrc.js (1)
  • packages/blade/.storybook/react-native/storybook.requires.js (2)
  • packages/blade/ios/blade.xcodeproj/project.pbxproj (13)
  • packages/blade/src/components/Counter/Counter.tsx (3)
  • packages/blade/src/components/Tabs/SafeSceneMap.native.tsx (1)
  • packages/blade/src/components/Tabs/TabIndicator.native.tsx (1)
  • packages/blade/src/components/Tabs/TabIndicator.web.tsx (1)
  • packages/blade/src/components/Tabs/TabItem.native.tsx (1)
  • packages/blade/src/components/Tabs/TabItem.web.tsx (1)
  • packages/blade/src/components/Tabs/TabList.native.tsx (1)
  • packages/blade/src/components/Tabs/TabList.web.tsx (1)
  • packages/blade/src/components/Tabs/TabPanel.native.tsx (1)
  • packages/blade/src/components/Tabs/TabPanel.web.tsx (1)
  • packages/blade/src/components/Tabs/Tabs.native.tsx (1)
  • packages/blade/src/components/Tabs/Tabs.stories.tsx (1)
  • packages/blade/src/components/Tabs/Tabs.web.tsx (1)
  • packages/blade/src/components/Tabs/TabsContext.ts (1)
  • packages/blade/src/components/Tabs/_KitchenSink.Tabs.stories.tsx (1)
  • packages/blade/src/components/Tabs/tests/Tabs.native.test.tsx (1)
  • packages/blade/src/components/Tabs/tests/Tabs.ssr.test.tsx (1)
  • packages/blade/src/components/Tabs/tests/Tabs.web.test.tsx (1)
  • packages/blade/src/components/Tabs/index.ts (1)
  • packages/blade/src/components/Tabs/tabTokens.ts (1)
  • packages/blade/src/components/Tabs/types.ts (1)
  • packages/blade/src/components/Tabs/utils.ts (1)
  • packages/blade/src/components/index.ts (1)
  • packages/blade/src/utils/metaAttribute/metaConstants.ts (1)
  • packages/blade/src/utils/useBreakpoint/useBreakpoint.ts (1)
  • packages/blade/src/utils/useControllable.ts (2)
Files ignored due to filter (6)
  • packages/blade/ios/Podfile.lock
  • packages/blade/package.json
  • packages/blade/src/components/Tabs/tests/snapshots/Tabs.native.test.tsx.snap
  • packages/blade/src/components/Tabs/tests/snapshots/Tabs.ssr.test.tsx.snap
  • packages/blade/src/components/Tabs/tests/snapshots/Tabs.web.test.tsx.snap
  • yarn.lock
Files not summarized due to errors (25)
  • packages/blade/ios/blade.xcodeproj/project.pbxproj (diff tokens exceeds limit)
  • packages/blade/src/components/Tabs/SafeSceneMap.native.tsx (nothing obtained from openai)
  • packages/blade/src/components/Tabs/TabIndicator.web.tsx (nothing obtained from openai)
  • packages/blade/.storybook/react-native/storybook.requires.js (nothing obtained from openai)
  • packages/blade/src/components/Tabs/TabIndicator.native.tsx (nothing obtained from openai)
  • packages/blade/src/components/Tabs/TabItem.native.tsx (nothing obtained from openai)
  • packages/blade/src/components/Tabs/Tabs.stories.tsx (diff tokens exceeds limit)
  • packages/blade/src/components/Tabs/TabList.web.tsx (nothing obtained from openai)
  • packages/blade/src/components/Tabs/TabList.native.tsx (nothing obtained from openai)
  • packages/blade/src/components/Tabs/TabItem.web.tsx (nothing obtained from openai)
  • packages/blade/src/components/Tabs/TabPanel.native.tsx (nothing obtained from openai)
  • packages/blade/src/components/Tabs/Tabs.native.tsx (nothing obtained from openai)
  • packages/blade/src/components/Tabs/tests/Tabs.web.test.tsx (diff tokens exceeds limit)
  • packages/blade/src/components/Tabs/Tabs.web.tsx (nothing obtained from openai)
  • packages/blade/src/components/Tabs/TabsContext.ts (nothing obtained from openai)
  • packages/blade/src/components/Tabs/_KitchenSink.Tabs.stories.tsx (nothing obtained from openai)
  • packages/blade/src/components/Tabs/tests/Tabs.ssr.test.tsx (nothing obtained from openai)
  • packages/blade/src/components/Tabs/tests/Tabs.native.test.tsx (nothing obtained from openai)
  • packages/blade/src/components/Tabs/tabTokens.ts (nothing obtained from openai)
  • packages/blade/src/components/Tabs/types.ts (nothing obtained from openai)
  • packages/blade/src/components/Tabs/utils.ts (nothing obtained from openai)
  • packages/blade/src/components/index.ts (nothing obtained from openai)
  • packages/blade/src/utils/metaAttribute/metaConstants.ts (nothing obtained from openai)
  • packages/blade/src/utils/useBreakpoint/useBreakpoint.ts (nothing obtained from openai)
  • packages/blade/src/utils/useControllable.ts (nothing obtained from openai)
Files not reviewed due to errors (25)
  • packages/blade/src/components/Tabs/TabIndicator.native.tsx (no response)
  • packages/blade/ios/blade.xcodeproj/project.pbxproj (no response)
  • packages/blade/.storybook/react-native/storybook.requires.js (no response)
  • packages/blade/src/components/Tabs/SafeSceneMap.native.tsx (no response)
  • packages/blade/src/components/Tabs/TabItem.native.tsx (no response)
  • packages/blade/src/components/Tabs/TabIndicator.web.tsx (no response)
  • packages/blade/src/components/Tabs/TabPanel.native.tsx (no response)
  • packages/blade/src/components/Tabs/TabList.web.tsx (no response)
  • packages/blade/src/components/Tabs/TabList.native.tsx (no response)
  • packages/blade/src/components/Tabs/Tabs.native.tsx (no response)
  • packages/blade/src/components/Tabs/TabItem.web.tsx (no response)
  • packages/blade/src/components/Tabs/TabPanel.web.tsx (no response)
  • packages/blade/src/components/Tabs/TabsContext.ts (no response)
  • packages/blade/src/components/Tabs/tests/Tabs.ssr.test.tsx (no response)
  • packages/blade/src/components/Tabs/_KitchenSink.Tabs.stories.tsx (no response)
  • packages/blade/src/components/Tabs/tests/Tabs.native.test.tsx (no response)
  • packages/blade/src/components/Tabs/Tabs.web.tsx (no response)
  • packages/blade/src/components/Tabs/tests/Tabs.web.test.tsx (no response)
  • packages/blade/src/utils/metaAttribute/metaConstants.ts (no response)
  • packages/blade/src/utils/useBreakpoint/useBreakpoint.ts (no response)
  • packages/blade/src/components/Tabs/utils.ts (no response)
  • packages/blade/src/components/Tabs/types.ts (no response)
  • packages/blade/src/components/Tabs/tabTokens.ts (no response)
  • packages/blade/src/components/index.ts (no response)
  • packages/blade/src/utils/useControllable.ts (no response)
Files skipped from review due to trivial changes (4)
  • .eslintrc.js
  • packages/blade/src/components/Counter/Counter.tsx
  • packages/blade/src/components/Tabs/index.ts
  • packages/blade/src/components/Tabs/Tabs.stories.tsx (diff too large)
Review comments generated (0)
  • Review: 0
  • LGTM: 0

Tips

Chat with Image description CodeRabbit Bot (@coderabbitai)

  • Reply on review comments left by this bot to ask follow-up questions. A review comment is a comment on a diff or a file.
  • Invite the bot into a review comment chain by tagging @coderabbitai in a reply.

Code suggestions

  • The bot may make code suggestions, but please review them carefully before committing since the line number ranges may be misaligned.
  • You can edit the comment made by the bot and manually tweak the suggestion if it is slightly off.

Pausing incremental reviews

  • Add @coderabbitai: ignore anywhere in the PR description to pause further reviews from the bot.

@bundlemon
Copy link

bundlemon bot commented Oct 27, 2023

BundleMon

Files updated (2)
Status Path Size Limits
Web Components
build/components/index.production.web.js
260.1KB (+4.45KB +1.74%) -
React Native Components
build/components/index.native.js
186KB (+2.65KB +1.45%) -
Unchanged files (12)
Status Path Size Limits
Web Tokens
build/tokens/index.production.web.js
42.26KB -
React Native Tokens
build/tokens/index.native.js
38.5KB -
CSS Theme Tokens
build/css/paymentThemeDarkDesktop.css
4.55KB -
CSS Theme Tokens
build/css/bankingThemeLightDesktop.css
4.54KB -
CSS Theme Tokens
build/css/paymentThemeDarkMobile.css
4.54KB -
CSS Theme Tokens
build/css/bankingThemeLightMobile.css
4.53KB -
CSS Theme Tokens
build/css/paymentThemeLightDesktop.css
4.53KB -
CSS Theme Tokens
build/css/bankingThemeDarkDesktop.css
4.52KB -
CSS Theme Tokens
build/css/paymentThemeLightMobile.css
4.52KB -
CSS Theme Tokens
build/css/bankingThemeDarkMobile.css
4.51KB -
Web Utils
build/utils/index.production.web.js
3.29KB -
React Native Utils
build/utils/index.native.js
2.26KB -

Total files change +7.1KB +1.27%

Final result: ✅

View report in BundleMon website ➡️


Current branch size history | Target branch size history

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Image description CodeRabbit

Commits Files that changed from the base of the PR and between 8fbd3d8 and d16fdfb commits.
Files selected (3)
  • packages/blade/src/components/Dropdown/tests/Dropdown.ssr.test.tsx (1)
  • packages/blade/src/components/Input/DropdownInputTriggers/tests/AutoComplete.ssr.test.tsx (1)
  • packages/blade/src/components/Tooltip/tests/Tooltip.ssr.test.tsx (1)
Files ignored due to filter (4)
  • packages/blade/package.json
  • packages/blade/src/components/Modal/tests/snapshots/Modal.web.test.tsx.snap
  • packages/blade/src/components/Popover/tests/snapshots/Popover.web.test.tsx.snap
  • yarn.lock
Files skipped from review due to trivial changes (3)
  • packages/blade/src/components/Dropdown/tests/Dropdown.ssr.test.tsx
  • packages/blade/src/components/Input/DropdownInputTriggers/tests/AutoComplete.ssr.test.tsx
  • packages/blade/src/components/Tooltip/tests/Tooltip.ssr.test.tsx
Review comments generated (0)
  • Review: 0
  • LGTM: 0

Tips

Chat with Image description CodeRabbit Bot (@coderabbitai)

  • Reply on review comments left by this bot to ask follow-up questions. A review comment is a comment on a diff or a file.
  • Invite the bot into a review comment chain by tagging @coderabbitai in a reply.

Code suggestions

  • The bot may make code suggestions, but please review them carefully before committing since the line number ranges may be misaligned.
  • You can edit the comment made by the bot and manually tweak the suggestion if it is slightly off.

Pausing incremental reviews

  • Add @coderabbitai: ignore anywhere in the PR description to pause further reviews from the bot.

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Image description CodeRabbit

Commits Files that changed from the base of the PR and between d16fdfb and 60a6d75 commits.
Files selected (1)
  • .changeset/breezy-dancers-breathe.md (1)
Files skipped from review due to trivial changes (1)
  • .changeset/breezy-dancers-breathe.md
Review comments generated (0)
  • Review: 0
  • LGTM: 0

Tips

Chat with Image description CodeRabbit Bot (@coderabbitai)

  • Reply on review comments left by this bot to ask follow-up questions. A review comment is a comment on a diff or a file.
  • Invite the bot into a review comment chain by tagging @coderabbitai in a reply.

Code suggestions

  • The bot may make code suggestions, but please review them carefully before committing since the line number ranges may be misaligned.
  • You can edit the comment made by the bot and manually tweak the suggestion if it is slightly off.

Pausing incremental reviews

  • Add @coderabbitai: ignore anywhere in the PR description to pause further reviews from the bot.

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Image description CodeRabbit

Commits Files that changed from the base of the PR and between 60a6d75 and 05d72ac commits.
Files selected (1)
  • .changeset/breezy-dancers-breathe.md (1)
Files not reviewed due to errors (1)
  • .changeset/breezy-dancers-breathe.md (no response)
Review comments generated (0)
  • Review: 0
  • LGTM: 0

Tips

Chat with Image description CodeRabbit Bot (@coderabbitai)

  • Reply on review comments left by this bot to ask follow-up questions. A review comment is a comment on a diff or a file.
  • Invite the bot into a review comment chain by tagging @coderabbitai in a reply.

Code suggestions

  • The bot may make code suggestions, but please review them carefully before committing since the line number ranges may be misaligned.
  • You can edit the comment made by the bot and manually tweak the suggestion if it is slightly off.

Pausing incremental reviews

  • Add @coderabbitai: ignore anywhere in the PR description to pause further reviews from the bot.

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Image description CodeRabbit

Commits Files that changed from the base of the PR and between 05d72ac and 689143a commits.
Files selected (1)
  • .changeset/breezy-dancers-breathe.md (1)
Files skipped from review due to trivial changes (1)
  • .changeset/breezy-dancers-breathe.md
Review comments generated (0)
  • Review: 0
  • LGTM: 0

Tips

Chat with Image description CodeRabbit Bot (@coderabbitai)

  • Reply on review comments left by this bot to ask follow-up questions. A review comment is a comment on a diff or a file.
  • Invite the bot into a review comment chain by tagging @coderabbitai in a reply.

Code suggestions

  • The bot may make code suggestions, but please review them carefully before committing since the line number ranges may be misaligned.
  • You can edit the comment made by the bot and manually tweak the suggestion if it is slightly off.

Pausing incremental reviews

  • Add @coderabbitai: ignore anywhere in the PR description to pause further reviews from the bot.

@anuraghazra anuraghazra merged commit fc7c840 into master Oct 30, 2023
@anuraghazra anuraghazra deleted the anu/tabs branch October 30, 2023 07:21
harsh9975 pushed a commit to harsh9975/blade that referenced this pull request Oct 31, 2023
* feat: tabs main logic & a11y implementation

* feat: animated indicator

* feat: add filled variant & perfect the animations

* feat: fixed paddings, refactored padding object & fixed vertical states

* chore: refactor tab tokens

* chore: minor refactors

* chore: rename components

* chore: only add border left on bordered variant

* fix: weird react state update bug, causing it to fail on certain cases

* chore: rename autoWidth prop

* feat: added isLazy prop

* refactor: redo paddings

* chore: border design changes

* chore: large font design change

* chore: add filled vertical variant example

* chore: add icon color in selected state

* feat: added support for href in tabitem

* chore: use media query for changing padding

* chore: added jsdoc

* chore: review comments

* feat(blade): tabs react-native implementation (razorpay#1707)

* feat: initial rn tabs

* feat: refactor tabs implementation

* fix: bug with sceneMap

* chore: fix tabbar filled width bug

* chore: fix initial value, androidshadow, indicator spacing

* chore: minor

* feat: added divider in filled tabs rn

* chore: update rn with new design

* chore: pass lazy prop

* chore: review comments

* chore: add comment

* chore: fix rn context type issue

* test: added Tabs web & native test (razorpay#1743)

* chore: added web tests

* chore: update snaps

* test: added more web tests

* chore: native test wip

* chore: rn tests

* chore: minor update

* chore: add ssr test

* chore: remove comments

* docs(blade): added documentation for tabs (razorpay#1715)

* docs: added examples/docs for tabs

* fix: vertical border taking up 100% height

* chore: minor changes

* chore: fix rn stories

* docs: added product usecases

* chore: update docs for react router

* chore: added kitchen sink

* chore: remove todo

* chore: update styled props of tablist

* chore: wrap with card

* chore: prevent vertical on mobile

* chore: update spacing

* chore: export tabs

* chore: fix rn stories

* chore: add meta attributes

* chore: remove version change

* chore: update snaps

* chore: update fialing tests

* Create breezy-dancers-breathe.md

* chore: update changelog

* chore: update changeset
anuraghazra added a commit that referenced this pull request Apr 9, 2024
* feat: tabs main logic & a11y implementation

* feat: animated indicator

* feat: add filled variant & perfect the animations

* feat: fixed paddings, refactored padding object & fixed vertical states

* chore: refactor tab tokens

* chore: minor refactors

* chore: rename components

* chore: only add border left on bordered variant

* fix: weird react state update bug, causing it to fail on certain cases

* chore: rename autoWidth prop

* feat: added isLazy prop

* refactor: redo paddings

* chore: border design changes

* chore: large font design change

* chore: add filled vertical variant example

* chore: add icon color in selected state

* feat: added support for href in tabitem

* chore: use media query for changing padding

* chore: added jsdoc

* chore: review comments

* feat(blade): tabs react-native implementation (#1707)

* feat: initial rn tabs

* feat: refactor tabs implementation

* fix: bug with sceneMap

* chore: fix tabbar filled width bug

* chore: fix initial value, androidshadow, indicator spacing

* chore: minor

* feat: added divider in filled tabs rn

* chore: update rn with new design

* chore: pass lazy prop

* chore: review comments

* chore: add comment

* chore: fix rn context type issue

* test: added Tabs web & native test (#1743)

* chore: added web tests

* chore: update snaps

* test: added more web tests

* chore: native test wip

* chore: rn tests

* chore: minor update

* chore: add ssr test

* chore: remove comments

* docs(blade): added documentation for tabs (#1715)

* docs: added examples/docs for tabs

* fix: vertical border taking up 100% height

* chore: minor changes

* chore: fix rn stories

* docs: added product usecases

* chore: update docs for react router

* chore: added kitchen sink

* chore: remove todo

* chore: update styled props of tablist

* chore: wrap with card

* chore: prevent vertical on mobile

* chore: update spacing

* chore: export tabs

* chore: fix rn stories

* chore: add meta attributes

* chore: remove version change

* chore: update snaps

* chore: update fialing tests

* Create breezy-dancers-breathe.md

* chore: update changelog

* chore: update changeset
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Review - L2 Second level of review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants