-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into 12520-table-batch-actions-type
- Loading branch information
Showing
278 changed files
with
5,657 additions
and
1,304 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed
BIN
-88.1 KB
.yarn/cache/@sinclair-typebox-npm-0.25.24-d04d0f45ef-10219c58f4.zip
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file renamed
BIN
+18.5 KB
...util-npm-29.5.0-cf917d20f1-fd9212950d.zip → ...util-npm-29.6.2-41bd0e8e02-8aedc0c800.zip
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file renamed
BIN
+21.5 KB
...rmat-npm-29.5.0-4f1086147d-4065356b55.zip → ...rmat-npm-29.6.2-7f39471065-a0f972a44f.zip
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
--- | ||
apiVersion: backstage.io/v1alpha1 | ||
kind: Component | ||
metadata: | ||
name: carbon | ||
description: Carbon is an open-source design system built by IBM | ||
tags: | ||
- carbon | ||
- designsystem | ||
annotations: | ||
github.com/project-slug: carbon-design-system/carbon | ||
links: | ||
- url: https://carbondesignsystem.com | ||
title: Carbon Design System website | ||
- url: https://ibm-studios.slack.com/archives/C0M053VPT | ||
title: Internal carbon-design-system Slack channel | ||
- url: https://discord.gg/J7JEUEkTRX | ||
title: Discord channel | ||
spec: | ||
type: library | ||
lifecycle: production | ||
owner: carbon | ||
--- | ||
apiVersion: backstage.io/v1alpha1 | ||
kind: Component | ||
metadata: | ||
name: carbon-react | ||
description: React components for the Carbon Design System | ||
tags: | ||
- carbon | ||
- react | ||
links: | ||
- url: http://react.carbondesignsystem.com | ||
title: Storybook | ||
- url: https://ibm-studios.slack.com/archives/C2K6RFJ1G | ||
title: Internal carbon-react slack channel | ||
- url: https://carbondesignsystem.com/developing/frameworks/react/ | ||
title: How-to docs and guidelines | ||
spec: | ||
type: library | ||
lifecycle: production | ||
subcomponentOf: carbon | ||
owner: carbon | ||
--- | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,118 @@ | ||
/** | ||
* Copyright IBM Corp. 2016, 2023 | ||
* | ||
* This source code is licensed under the Apache-2.0 license found in the | ||
* LICENSE file in the root directory of this source tree. | ||
*/ | ||
|
||
'use strict'; | ||
|
||
const { expect, test } = require('@playwright/test'); | ||
const { visitStory } = require('../../test-utils/storybook'); | ||
|
||
test.describe('ComboBox @avt', () => { | ||
test('accessibility-checker combobox', async ({ page }) => { | ||
await visitStory(page, { | ||
component: 'ComboBox', | ||
id: 'components-combobox--default', | ||
globals: { | ||
theme: 'white', | ||
}, | ||
}); | ||
await expect(page).toHaveNoACViolations('ComboBox'); | ||
}); | ||
|
||
// Skipping now due to AVT violation, possible false positive | ||
test.skip('accessibility-checker open combobox', async ({ page }) => { | ||
await visitStory(page, { | ||
component: 'ComboBox', | ||
id: 'components-combobox--default', | ||
globals: { | ||
theme: 'white', | ||
}, | ||
}); | ||
const combobox = page.getByRole('combobox'); | ||
|
||
await expect(combobox).toBeVisible(); | ||
// Tab and open the ComboBox | ||
await page.keyboard.press('Tab'); | ||
await expect(combobox).toBeFocused(); | ||
await page.keyboard.press('Enter'); | ||
await expect(page.getByRole('combobox', { expanded: true })).toBeVisible; | ||
await expect(combobox).toBeFocused(); | ||
|
||
await expect(page).toHaveNoACViolations('ComboBox-open'); | ||
}); | ||
|
||
test('combobox - keyboard nav', async ({ page }) => { | ||
await visitStory(page, { | ||
component: 'ComboBox', | ||
id: 'components-combobox--default', | ||
globals: { | ||
theme: 'white', | ||
}, | ||
}); | ||
const combobox = page.getByRole('combobox'); | ||
const menu = page.getByRole('listbox'); | ||
const clearButton = page.getByRole('button', { | ||
name: 'Clear selected item', | ||
}); | ||
const optionOne = page.getByRole('option', { | ||
name: 'An example option that is really long to show what should be done to handle long text', | ||
}); | ||
const optionTwo = page.getByRole('option', { | ||
name: 'Option 2', | ||
}); | ||
|
||
await expect(combobox).toBeVisible(); | ||
await expect(clearButton).not.toBeVisible(); | ||
// Tab and open the ComboBox with Arrow Down | ||
await page.keyboard.press('Tab'); | ||
await expect(combobox).toBeFocused(); | ||
await page.keyboard.press('ArrowDown'); | ||
await expect(menu).toBeVisible(); | ||
// Close with Escape, retain focus, and open with Spacebar | ||
await page.keyboard.press('Escape'); | ||
await expect(menu).not.toBeVisible(); | ||
await expect(combobox).toBeFocused(); | ||
await page.keyboard.press('Space'); | ||
await expect(menu).toBeVisible(); | ||
// Close and clear with Escape, retain focus, and open with Enter | ||
await page.keyboard.press('Escape'); | ||
await page.keyboard.press('Escape'); | ||
await expect(menu).not.toBeVisible(); | ||
await expect(combobox).toBeFocused(); | ||
await page.keyboard.press('Enter'); | ||
await expect(menu).toBeVisible(); | ||
// Navigation inside the menu | ||
// move to first option | ||
await page.keyboard.press('ArrowDown'); | ||
await expect(optionOne).toHaveClass( | ||
'cds--list-box__menu-item cds--list-box__menu-item--highlighted' | ||
); | ||
// select first option (should only select with enter) | ||
await page.keyboard.press('Space'); | ||
await expect(combobox).toHaveValue(' '); | ||
await page.keyboard.press('Enter'); | ||
await expect(combobox).toHaveValue( | ||
'An example option that is really long to show what should be done to handle long text' | ||
); | ||
// focus comes back to the toggle button after selecting | ||
await expect(combobox).toBeFocused(); | ||
await expect(menu).not.toBeVisible(); | ||
await expect(clearButton).toBeVisible(); | ||
// should only clear selection when escape is pressed when the menu is closed | ||
await page.keyboard.press('Escape'); | ||
await expect(clearButton).not.toBeVisible(); | ||
await expect(combobox).toHaveValue(''); | ||
// should highlight menu items based on text input | ||
await page.keyboard.press('2'); | ||
await expect(menu).toBeVisible(); | ||
await expect(optionTwo).toHaveClass( | ||
'cds--list-box__menu-item cds--list-box__menu-item--highlighted' | ||
); | ||
// Should select and populate combobox with current filtered item | ||
await page.keyboard.press('Enter'); | ||
await expect(combobox).toHaveValue('Option 2'); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.