-
-
Notifications
You must be signed in to change notification settings - Fork 263
WIP: SelectableTileGroup #439
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
Open
ispyinternet
wants to merge
57
commits into
carbon-design-system:master
Choose a base branch
from
ispyinternet:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 21 commits
Commits
Show all changes
57 commits
Select commit
Hold shift + click to select a range
9af756b
Add padding prop to Grid component
ispyinternet 06ecbe7
Fix file name
ispyinternet 585341d
Build lib
ispyinternet 47f6292
Merge master
ispyinternet f17b35d
Typo
ispyinternet 3c59a6c
Move DataTableSkelton 3119restProps to container
ispyinternet 36987b2
Merge branch 'master' of github.com:IBM/carbon-components-svelte
ispyinternet 626fd99
Merge branch 'master' of github.com:IBM/carbon-components-svelte
ispyinternet fe5c571
WIP: SelectableTileGroup
ispyinternet 184c3d9
Some fixes
ispyinternet 5f5293a
Some fixes
ispyinternet 94f5965
Some fixes
ispyinternet d874180
Some fixes
ispyinternet a249b61
Some fixes
ispyinternet b5ec601
Some fixes
ispyinternet 060b53b
Some fixes
ispyinternet 1d1fe47
Some fixes
ispyinternet 98cee82
Some fixes
ispyinternet 4c3ea78
Some fixes
ispyinternet 5b9bc98
Some fixes
ispyinternet 5ef181d
Remove light prop from SelectableTileGroup
ispyinternet 746ce92
implement change requests
ispyinternet 10da838
add build
ispyinternet 480337f
implement change requests
ispyinternet c37d7b3
Strip out RadioTileGroup
ispyinternet b83d6ad
update fix required for both branches of the if statement! - may as w…
ispyinternet ed9d109
Fix failing RadioTile test
ispyinternet 80f49f6
Prepare for pull request
ispyinternet 4665e28
chore: delete RadioTileGroup.d.ts
metonym de1c2d0
Fix binding bug
ispyinternet 17a77b6
Merge remote-tracking branch 'origin/master'
ispyinternet ce8e0b2
Merge remote-tracking branch 'ispyinternet/master'
ispyinternet ef76f2c
Revert RadioTile tabindex
ispyinternet 9db8f9d
Support fieldset disabled
ispyinternet 95bfb72
Support fieldset disabled
ispyinternet 21f75af
Merge branch 'master' of github.com:ispyinternet/carbon-components-sv…
ispyinternet 5a11a49
Move tabindex to input element
ispyinternet b380393
docs(selectable-tile): add use cases
metonym 03b7be1
chore: reset selected value in controlled example
metonym 5a4328e
try to fix reactivity
ispyinternet 70d50f7
try to fix reactivity
ispyinternet 677f6b5
try to fix reactivity
ispyinternet 37dd97e
try to fix reactivity
ispyinternet fe84e9a
try to fix reactivity
ispyinternet 3b1efdd
try to fix reactivity
ispyinternet b5d641d
try to fix reactivity
ispyinternet 4d82e78
try to fix reactivity
ispyinternet 1c0f7e7
try to fix reactivity
ispyinternet 7cd0df9
try to fix reactivity
ispyinternet 52240c6
try to fix reactivity
ispyinternet e6fdda5
try to fix reactivity
ispyinternet 8431b58
try to fix reactivity
ispyinternet 172f54e
try to fix reactivity
ispyinternet 7b3144f
try to fix reactivity
ispyinternet ac99f8f
try to fix reactivity
ispyinternet cbdf10d
try to fix reactivity
ispyinternet 7373aa3
try to fix reactivity
ispyinternet File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or 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 |
|---|---|---|
| @@ -1,6 +1,6 @@ | ||
| # Component Index | ||
|
|
||
| > 155 components exported from [email protected]. | ||
| > 157 components exported from [email protected]. | ||
|
|
||
| ## Components | ||
|
|
||
|
|
@@ -97,6 +97,7 @@ | |
| - [`RadioButtonGroup`](#radiobuttongroup) | ||
| - [`RadioButtonSkeleton`](#radiobuttonskeleton) | ||
| - [`RadioTile`](#radiotile) | ||
| - [`RadioTileGroup`](#radiotilegroup) | ||
| - [`Row`](#row) | ||
| - [`Search`](#search) | ||
| - [`SearchSkeleton`](#searchskeleton) | ||
|
|
@@ -105,6 +106,7 @@ | |
| - [`SelectItemGroup`](#selectitemgroup) | ||
| - [`SelectSkeleton`](#selectskeleton) | ||
| - [`SelectableTile`](#selectabletile) | ||
| - [`SelectableTileGroup`](#selectabletilegroup) | ||
| - [`SideNav`](#sidenav) | ||
| - [`SideNavItems`](#sidenavitems) | ||
| - [`SideNavLink`](#sidenavlink) | ||
|
|
@@ -2692,15 +2694,17 @@ None. | |
|
|
||
| ### Props | ||
|
|
||
| | Prop name | Kind | Reactive | Type | Default value | Description | | ||
| | :-------------- | :--------------- | :------- | :------------------- | ------------------------------------------------ | -------------------------------------------------------- | | ||
| | checked | <code>let</code> | Yes | <code>boolean</code> | <code>false</code> | Set to `true` to check the tile | | ||
| | light | <code>let</code> | No | <code>boolean</code> | <code>false</code> | Set to `true` to enable the light variant | | ||
| | value | <code>let</code> | No | <code>string</code> | <code>""</code> | Specify the value of the radio input | | ||
| | tabindex | <code>let</code> | No | <code>string</code> | <code>"0"</code> | Specify the tabindex | | ||
| | iconDescription | <code>let</code> | No | <code>string</code> | <code>"Tile checkmark"</code> | Specify the ARIA label for the radio tile checkmark icon | | ||
| | id | <code>let</code> | No | <code>string</code> | <code>"ccs-" + Math.random().toString(36)</code> | Set an id for the input element | | ||
| | name | <code>let</code> | No | <code>string</code> | <code>""</code> | Specify a name attribute for the input | | ||
| | Prop name | Kind | Reactive | Type | Default value | Description | | ||
| | :-------------- | :--------------- | :------- | :---------------------------------------- | ------------------------------------------------ | -------------------------------------------------------- | | ||
| | ref | <code>let</code> | Yes | <code>null | HTMLInputElement</code> | <code>null</code> | Obtain a reference to the input HTML element | | ||
| | checked | <code>let</code> | Yes | <code>boolean</code> | <code>false</code> | Set to `true` to check the tile | | ||
| | light | <code>let</code> | No | <code>boolean</code> | <code>false</code> | Set to `true` to enable the light variant | | ||
| | value | <code>let</code> | No | <code>string</code> | <code>""</code> | Specify the value of the radio input | | ||
| | title | <code>let</code> | No | <code>string</code> | <code>"title"</code> | Specify the title of the selectable tile | | ||
| | tabindex | <code>let</code> | No | <code>string</code> | <code>"0"</code> | Specify the tabindex | | ||
| | iconDescription | <code>let</code> | No | <code>string</code> | <code>"Tile checkmark"</code> | Specify the ARIA label for the radio tile checkmark icon | | ||
| | id | <code>let</code> | No | <code>string</code> | <code>"ccs-" + Math.random().toString(36)</code> | Set an id for the input element | | ||
| | name | <code>let</code> | No | <code>string</code> | <code>""</code> | Specify a name attribute for the input | | ||
|
|
||
| ### Slots | ||
|
|
||
|
|
@@ -2719,6 +2723,28 @@ None. | |
| | mouseenter | forwarded | -- | | ||
| | mouseleave | forwarded | -- | | ||
|
|
||
| ## `RadioTileGroup` | ||
|
|
||
| ### Props | ||
|
|
||
| | Prop name | Kind | Reactive | Type | Default value | Description | | ||
| | :------------ | :--------------- | :------- | :------------------- | ------------------ | --------------------------------------- | | ||
| | selectedValue | <code>let</code> | Yes | <code>any</code> | -- | Specify the selected tile value | | ||
| | disabled | <code>let</code> | No | <code>boolean</code> | <code>false</code> | Set to `true` to disable the tile group | | ||
| | legend | <code>let</code> | No | <code>string</code> | <code>""</code> | Specify the legend text | | ||
|
|
||
| ### Slots | ||
|
|
||
| | Slot name | Default | Props | Fallback | | ||
| | :-------- | :------ | :---- | :------- | | ||
| | -- | Yes | -- | -- | | ||
|
|
||
| ### Events | ||
|
|
||
| | Event name | Type | Detail | | ||
| | :--------- | :--------- | :----- | | ||
| | select | dispatched | -- | | ||
|
|
||
| ## `Row` | ||
|
|
||
| ### Props | ||
|
|
@@ -2929,6 +2955,28 @@ None. | |
| | mouseleave | forwarded | -- | | ||
| | keydown | forwarded | -- | | ||
|
|
||
| ## `SelectableTileGroup` | ||
|
|
||
| ### Props | ||
|
|
||
| | Prop name | Kind | Reactive | Type | Default value | Description | | ||
| | :------------- | :--------------- | :------- | :------------------- | ------------------ | --------------------------------------- | | ||
| | selectedValues | <code>let</code> | Yes | <code>any[]</code> | <code>[]</code> | Specify the selected tile's | | ||
| | disabled | <code>let</code> | No | <code>boolean</code> | <code>false</code> | Set to `true` to disable the tile group | | ||
| | legend | <code>let</code> | No | <code>string</code> | <code>""</code> | Specify the legend text | | ||
|
|
||
| ### Slots | ||
|
|
||
| | Slot name | Default | Props | Fallback | | ||
| | :-------- | :------ | :---- | :------- | | ||
| | -- | Yes | -- | -- | | ||
|
|
||
| ### Events | ||
|
|
||
| | Event name | Type | Detail | | ||
| | :--------- | :--------- | :----- | | ||
| | select | dispatched | -- | | ||
|
|
||
| ## `SideNav` | ||
|
|
||
| ### Props | ||
|
|
||
This file contains hidden or 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 hidden or 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 hidden or 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 |
|---|---|---|
| @@ -1,36 +1,22 @@ | ||
| --- | ||
| components: ["SelectableTile"] | ||
| components: ["SelectableTile", "SelectableTileGroup"] | ||
| --- | ||
|
|
||
| <script> | ||
| import { SelectableTile } from "carbon-components-svelte"; | ||
| import { SelectableTile, SelectableTileGroup } from "carbon-components-svelte"; | ||
| import Preview from "../../components/Preview.svelte"; | ||
| </script> | ||
|
|
||
| ### Multi-selectable tiles | ||
|
|
||
| <div role="group" aria-label="selectable tiles"> | ||
| <SelectableTile selected> | ||
| Multi-select Tile | ||
| <SelectableTileGroup legend="Select the options you require"> | ||
| <SelectableTile title="Option 1" value="option1" selected> | ||
| Option 1 | ||
| </SelectableTile> | ||
| <SelectableTile selected> | ||
| Multi-select Tile | ||
| <SelectableTile title="Option 2" value="2" selected> | ||
| Option 2 | ||
| </SelectableTile> | ||
| <SelectableTile> | ||
| Multi-select Tile | ||
| <SelectableTile title="Option 3" value="3"> | ||
| Option 3 | ||
| </SelectableTile> | ||
| </div> | ||
|
|
||
| ### Light variant | ||
|
|
||
| <div role="group" aria-label="selectable tiles"> | ||
| <SelectableTile light selected> | ||
| Multi-select Tile | ||
| </SelectableTile> | ||
| <SelectableTile light selected> | ||
| Multi-select Tile | ||
| </SelectableTile> | ||
| <SelectableTile light> | ||
| Multi-select Tile | ||
| </SelectableTile> | ||
| </div> | ||
| </SelectableTileGroup> |
This file contains hidden or 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 hidden or 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.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.