@coinbase/cds-common 9.15.0 → 9.17.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -8,6 +8,16 @@ All notable changes to this project will be documented in this file.
8
8
 
9
9
  <!-- template-start -->
10
10
 
11
+ ## 9.17.0 ((8/14/2026, 07:06 PM PST))
12
+
13
+ This is an artificial version bump with no new change.
14
+
15
+ ## 9.16.0 (8/13/2026 PST)
16
+
17
+ #### 🚀 Updates
18
+
19
+ - Add utility for SelectChip to share across packages. [[#843](https://github.com/coinbase/cds/pull/843)]
20
+
11
21
  ## 9.15.0 ((8/11/2026, 12:23 PM PST))
12
22
 
13
23
  This is an artificial version bump with no new change.
@@ -0,0 +1,21 @@
1
+ /**
2
+ * SelectChip selection: a single option, a multi-select list, or empty.
3
+ */
4
+ type SelectChipValue = string | readonly string[] | null | undefined;
5
+ /**
6
+ * Whether a SelectChip value represents a current selection.
7
+ */
8
+ export declare function getSelectChipHasValue(value: SelectChipValue): boolean;
9
+ /**
10
+ * Resolves SelectChip `active` from an explicit prop, legacy invert props, or the current selection.
11
+ * Explicit `active={false}` stays inactive even when a value is selected.
12
+ * When `active` is omitted and neither legacy invert prop is set, defaults to whether a value is selected.
13
+ */
14
+ export declare function getSelectChipActive(
15
+ active: boolean | undefined,
16
+ value: SelectChipValue,
17
+ invertColorScheme?: boolean,
18
+ inverted?: boolean,
19
+ ): boolean;
20
+ export {};
21
+ //# sourceMappingURL=getSelectChipActive.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getSelectChipActive.d.ts","sourceRoot":"","sources":["../../src/chips/getSelectChipActive.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,KAAK,eAAe,GAAG,MAAM,GAAG,SAAS,MAAM,EAAE,GAAG,IAAI,GAAG,SAAS,CAAC;AAErE;;GAEG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,eAAe,GAAG,OAAO,CAErE;AAED;;;;GAIG;AACH,wBAAgB,mBAAmB,CACjC,MAAM,EAAE,OAAO,GAAG,SAAS,EAC3B,KAAK,EAAE,eAAe,EACtB,iBAAiB,CAAC,EAAE,OAAO,EAC3B,QAAQ,CAAC,EAAE,OAAO,GACjB,OAAO,CAOT"}
@@ -0,0 +1,19 @@
1
+ /**
2
+ * SelectChip selection: a single option, a multi-select list, or empty.
3
+ */
4
+
5
+ /**
6
+ * Whether a SelectChip value represents a current selection.
7
+ */
8
+ export function getSelectChipHasValue(value) {
9
+ return value != null && !(Array.isArray(value) && value.length === 0);
10
+ }
11
+
12
+ /**
13
+ * Resolves SelectChip `active` from an explicit prop, legacy invert props, or the current selection.
14
+ * Explicit `active={false}` stays inactive even when a value is selected.
15
+ * When `active` is omitted and neither legacy invert prop is set, defaults to whether a value is selected.
16
+ */
17
+ export function getSelectChipActive(active, value, invertColorScheme, inverted) {
18
+ return active !== null && active !== void 0 ? active : invertColorScheme === undefined && inverted === undefined ? getSelectChipHasValue(value) : false;
19
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@coinbase/cds-common",
3
- "version": "9.15.0",
3
+ "version": "9.17.0",
4
4
  "description": "Coinbase Design System - Common",
5
5
  "repository": {
6
6
  "type": "git",
@@ -38,8 +38,8 @@
38
38
  },
39
39
  "dependencies": {
40
40
  "@coinbase/cds-icons": "^5.21.0",
41
- "@coinbase/cds-illustrations": "^4.47.0",
42
- "@coinbase/cds-mcp-server": "^9.15.0",
41
+ "@coinbase/cds-illustrations": "^4.48.0",
42
+ "@coinbase/cds-mcp-server": "^9.17.0",
43
43
  "@coinbase/cds-utils": "^2.3.5",
44
44
  "@modelcontextprotocol/sdk": "^1.13.1",
45
45
  "d3-array": "^3.2.4",