ds-one 0.1.11-alpha.12 → 0.1.11-alpha.14

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.
@@ -57,8 +57,15 @@ export function getDeviceInfo(): DeviceInfo {
57
57
  const touchPoints = (nav && nav.maxTouchPoints) || 0;
58
58
  const isTouchCapable = touchPoints > 1;
59
59
 
60
- const screenWidth = win?.innerWidth || 0;
61
- const screenHeight = win?.innerHeight || 0;
60
+ // Use clientWidth instead of innerWidth to exclude scrollbars
61
+ const screenWidth =
62
+ typeof document !== "undefined"
63
+ ? document.documentElement.clientWidth
64
+ : win?.innerWidth || 0;
65
+ const screenHeight =
66
+ typeof document !== "undefined"
67
+ ? document.documentElement.clientHeight
68
+ : win?.innerHeight || 0;
62
69
  const isTablet = isMobile && Math.min(screenWidth, screenHeight) >= 600;
63
70
 
64
71
  return {
@@ -1,4 +1,4 @@
1
- /* version 0.1.11-alpha.8 */
1
+ /* version 0.1.11-alpha.14 */
2
2
 
3
3
  input {
4
4
  padding: 0;
package/README.md CHANGED
@@ -27,7 +27,7 @@ npm install ds-one@alpha
27
27
  yarn add ds-one@alpha
28
28
  ```
29
29
 
30
- **Note**: Currently published as alpha version `0.1.11-alpha.12`. Use `@alpha` tag to install.
30
+ **Note**: Currently published as alpha version `0.1.11-alpha.14`. Use `@alpha` tag to install.
31
31
 
32
32
  ### Basic Usage
33
33
 
@@ -90,7 +90,7 @@ Try DS one in your browser: **[dsone.dev](https://dsone.dev)** (documentation sl
90
90
  - **[Internationalization](./docs/i18n.md)** - Language keys and Notion CMS setup
91
91
  - **[Examples](./docs/examples.md)** - Usage examples and patterns
92
92
 
93
- ## Current Status: v0.1.11-alpha.0
93
+ ## Current Status: v0.1.11-alpha.14
94
94
 
95
95
  **⚠️ Alpha Release**: This is an early alpha version. The API may change as we refine the components and architecture.
96
96
 
@@ -187,10 +187,10 @@ bun run build
187
187
 
188
188
  ```bash
189
189
  # Create a new release
190
- bun run release:patch # 0.1.11-alpha.0 → 0.1.12-alpha.0
191
- bun run release:minor # 0.1.11-alpha.0 → 0.2.0-alpha.0
192
- bun run release:major # 0.1.11-alpha.0 → 1.0.0
193
- bun run release:beta # 0.1.11-alpha.0 → 0.2.0-beta.0
190
+ bun run release:patch # 0.1.11-alpha.14 → 0.1.11-alpha.14
191
+ bun run release:minor # 0.1.11-alpha.14 → 0.1.11-alpha.14
192
+ bun run release:major # 0.1.11-alpha.14 → 1.0.0
193
+ bun run release:beta # 0.1.11-alpha.14 → 0.1.11-alpha.14
194
194
  ```
195
195
 
196
196
  ## License
@@ -1 +1 @@
1
- {"version":3,"file":"2025-04-23-device.d.ts","sourceRoot":"","sources":["../../DS1/0-face/2025-04-23-device.ts"],"names":[],"mappings":"AAGA,MAAM,MAAM,UAAU,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,CAAC;AAEzD,MAAM,WAAW,UAAU;IACzB,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,EAAE,OAAO,CAAC;IAClB,SAAS,EAAE,OAAO,CAAC;IACnB,cAAc,EAAE,OAAO,CAAC;IACxB,UAAU,EAAE,UAAU,CAAC;IACvB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,MAAM,CAAC;CACtB;AAED;;;GAGG;AACH,wBAAgB,kBAAkB,IAAI,OAAO,CA0B5C;AAED;;GAEG;AACH,wBAAgB,aAAa,IAAI,UAAU,CAsB1C;AAED;;GAEG;AACH,wBAAgB,mBAAmB,IAAI,UAAU,CA8ChD"}
1
+ {"version":3,"file":"2025-04-23-device.d.ts","sourceRoot":"","sources":["../../DS1/0-face/2025-04-23-device.ts"],"names":[],"mappings":"AAGA,MAAM,MAAM,UAAU,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,CAAC;AAEzD,MAAM,WAAW,UAAU;IACzB,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,EAAE,OAAO,CAAC;IAClB,SAAS,EAAE,OAAO,CAAC;IACnB,cAAc,EAAE,OAAO,CAAC;IACxB,UAAU,EAAE,UAAU,CAAC;IACvB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,MAAM,CAAC;CACtB;AAED;;;GAGG;AACH,wBAAgB,kBAAkB,IAAI,OAAO,CA0B5C;AAED;;GAEG;AACH,wBAAgB,aAAa,IAAI,UAAU,CA6B1C;AAED;;GAEG;AACH,wBAAgB,mBAAmB,IAAI,UAAU,CA8ChD"}
@@ -31,8 +31,13 @@ export function getDeviceInfo() {
31
31
  const win = window;
32
32
  const touchPoints = (nav && nav.maxTouchPoints) || 0;
33
33
  const isTouchCapable = touchPoints > 1;
34
- const screenWidth = win?.innerWidth || 0;
35
- const screenHeight = win?.innerHeight || 0;
34
+ // Use clientWidth instead of innerWidth to exclude scrollbars
35
+ const screenWidth = typeof document !== "undefined"
36
+ ? document.documentElement.clientWidth
37
+ : win?.innerWidth || 0;
38
+ const screenHeight = typeof document !== "undefined"
39
+ ? document.documentElement.clientHeight
40
+ : win?.innerHeight || 0;
36
41
  const isTablet = isMobile && Math.min(screenWidth, screenHeight) >= 600;
37
42
  return {
38
43
  isMobile,
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=ds-button.figma.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ds-button.figma.d.ts","sourceRoot":"","sources":["../../DS1/2-core/ds-button.figma.ts"],"names":[],"mappings":""}
@@ -0,0 +1,6 @@
1
+ import figma from "@figma/code-connect";
2
+ import html from "@figma/code-connect/html";
3
+ figma.connect("https://www.figma.com/design/XAnoaRoq9LxVAHUZgtdO0r/DS-one?node-id=1-6", {
4
+ props: {},
5
+ example: () => html `<ds-button>Button</ds-button>`,
6
+ });
@@ -18,8 +18,8 @@ function getDeviceInfo() {
18
18
  const win = window;
19
19
  const touchPoints = nav && nav.maxTouchPoints || 0;
20
20
  const isTouchCapable = touchPoints > 1;
21
- const screenWidth = win?.innerWidth || 0;
22
- const screenHeight = win?.innerHeight || 0;
21
+ const screenWidth = typeof document !== "undefined" ? document.documentElement.clientWidth : win?.innerWidth || 0;
22
+ const screenHeight = typeof document !== "undefined" ? document.documentElement.clientHeight : win?.innerHeight || 0;
23
23
  const isTablet = isMobile && Math.min(screenWidth, screenHeight) >= 600;
24
24
  return {
25
25
  isMobile,