From df06b38f442c386347aba9f3108de25b77637b69 Mon Sep 17 00:00:00 2001 From: Muhammad Amien Date: Wed, 8 May 2024 01:09:43 +0700 Subject: [PATCH] fix: pagination & tab --- packages/components/pagination/CHANGELOG.md | 24 +++++++++++++++++++ packages/components/pagination/package.json | 2 +- .../pagination/src/use-pagination-item.ts | 3 ++- packages/components/tabs/CHANGELOG.md | 6 +++++ packages/components/tabs/package.json | 2 +- packages/components/tabs/src/tab.tsx | 1 + packages/core/react/CHANGELOG.md | 24 +++++++++++++++++++ packages/core/react/package.json | 2 +- 8 files changed, 60 insertions(+), 4 deletions(-) diff --git a/packages/components/pagination/CHANGELOG.md b/packages/components/pagination/CHANGELOG.md index a1a57721..5c2f06f8 100644 --- a/packages/components/pagination/CHANGELOG.md +++ b/packages/components/pagination/CHANGELOG.md @@ -1,5 +1,29 @@ # @jala-banyu/pagination +## 1.1.38 + +### Patch Changes + +- fix typo aria attribute + +## 1.1.37 + +### Patch Changes + +- testing change role to aria-role + +## 1.1.36 + +### Patch Changes + +- remove duplicated role on pagination + +## 1.1.35 + +### Patch Changes + +- fixing accessibility + ## 1.1.34 ### Patch Changes diff --git a/packages/components/pagination/package.json b/packages/components/pagination/package.json index 0d420145..92eee565 100644 --- a/packages/components/pagination/package.json +++ b/packages/components/pagination/package.json @@ -1,6 +1,6 @@ { "name": "@jala-banyu/pagination", - "version": "1.1.34", + "version": "1.1.38", "description": "The Pagination component allows you to display active page and navigate between multiple pages.", "keywords": [ "pagination" diff --git a/packages/components/pagination/src/use-pagination-item.ts b/packages/components/pagination/src/use-pagination-item.ts index 1962b0f7..84beceba 100644 --- a/packages/components/pagination/src/use-pagination-item.ts +++ b/packages/components/pagination/src/use-pagination-item.ts @@ -87,7 +87,8 @@ export function usePaginationItem(props: UsePaginationItemProps) { const getItemProps: PropGetter = (props = {}) => { return { ref: domRef, - role: "button", + "aria-role": "button", + // role: "button", tabIndex: isDisabled ? -1 : 0, "aria-label": ariaLabel, "aria-current": dataAttr(isActive), diff --git a/packages/components/tabs/CHANGELOG.md b/packages/components/tabs/CHANGELOG.md index cb86bfdb..63d11243 100644 --- a/packages/components/tabs/CHANGELOG.md +++ b/packages/components/tabs/CHANGELOG.md @@ -1,5 +1,11 @@ # @jala-banyu/tabs +## 1.1.4 + +### Patch Changes + +- fixing accessibility + ## 1.1.3 ### Patch Changes diff --git a/packages/components/tabs/package.json b/packages/components/tabs/package.json index cb5106e5..c06de691 100644 --- a/packages/components/tabs/package.json +++ b/packages/components/tabs/package.json @@ -1,6 +1,6 @@ { "name": "@jala-banyu/tabs", - "version": "1.1.3", + "version": "1.1.4", "description": "Tabs organize content into multiple sections and allow users to navigate between them.", "keywords": [ "tabs" diff --git a/packages/components/tabs/src/tab.tsx b/packages/components/tabs/src/tab.tsx index 129cca74..331fe4f1 100644 --- a/packages/components/tabs/src/tab.tsx +++ b/packages/components/tabs/src/tab.tsx @@ -99,6 +99,7 @@ const Tab = forwardRef<"button", TabItemProps>((props, ref) => { data-pressed={dataAttr(isPressed)} data-selected={dataAttr(isSelected)} data-slot="tab" + role="button" {...mergeProps( tabProps, !isDisabled diff --git a/packages/core/react/CHANGELOG.md b/packages/core/react/CHANGELOG.md index e1b183b0..9469c6e5 100644 --- a/packages/core/react/CHANGELOG.md +++ b/packages/core/react/CHANGELOG.md @@ -1,5 +1,29 @@ # @jala-banyu/react +## 1.3.10 + +### Patch Changes + +- fix aria attribute + +## 1.3.9 + +### Patch Changes + +- testing aria label pagination + +## 1.3.8 + +### Patch Changes + +- update pagination + +## 1.3.7 + +### Patch Changes + +- fix accesibility + ## 1.3.6 ### Patch Changes diff --git a/packages/core/react/package.json b/packages/core/react/package.json index 4d257d95..d80fe7a8 100644 --- a/packages/core/react/package.json +++ b/packages/core/react/package.json @@ -1,6 +1,6 @@ { "name": "@jala-banyu/react", - "version": "1.3.6", + "version": "1.3.10", "description": "Banyu core React UI library", "author": "Muhammad Amien ", "homepage": "#",