@lism-css/ui 0.8.0 → 0.9.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lism-css/ui",
3
- "version": "0.8.0",
3
+ "version": "0.9.0",
4
4
  "description": "UI components by lism-css.",
5
5
  "author": {
6
6
  "name": "ddryo",
@@ -39,20 +39,20 @@
39
39
  "url": "https://github.com/lism-css/lism-css/issues"
40
40
  },
41
41
  "dependencies": {
42
- "lism-css": "0.8.4"
42
+ "lism-css": "0.9.0"
43
43
  },
44
44
  "devDependencies": {
45
- "@babel/cli": "^7.27.2",
46
- "@babel/core": "^7.27.3",
47
- "@babel/preset-env": "^7.27.2",
48
- "@babel/preset-react": "^7.27.1",
49
- "@rollup/plugin-babel": "^6.0.4",
50
- "@vitejs/plugin-react-swc": "^3.10.0",
51
- "glob": "^11.0.2",
52
- "rollup": "^4.41.1",
45
+ "@babel/cli": "^7.28.6",
46
+ "@babel/core": "^7.29.0",
47
+ "@babel/preset-env": "^7.29.0",
48
+ "@babel/preset-react": "^7.28.5",
49
+ "@rollup/plugin-babel": "^6.1.0",
50
+ "@vitejs/plugin-react-swc": "^3.11.0",
51
+ "glob": "^13.0.6",
52
+ "rollup": "^4.59.0",
53
53
  "typescript": "~5.8.3",
54
54
  "unplugin-dts": "1.0.0-beta.6",
55
- "vite": "^6.3.5"
55
+ "vite": "^6.4.1"
56
56
  },
57
57
  "peerDependencies": {
58
58
  "@types/react": "*",
@@ -2,7 +2,7 @@ import atts from 'lism-css/lib/helper/atts';
2
2
 
3
3
  export function getRootProps({ lismClass, allowMultiple, ...props }) {
4
4
  props.lismClass = atts(lismClass, 'c--accordion');
5
- if (allowMultiple) props['data-allow-multiple'] = 'true';
5
+ if (allowMultiple) props['data-allow-multiple'] = '';
6
6
  return props;
7
7
  }
8
8
 
@@ -9,14 +9,7 @@ export type AlertProps = {
9
9
  [key: string]: unknown;
10
10
  };
11
11
 
12
- export default function getAlertProps({
13
- type = 'alert',
14
- keycolor,
15
- layout = 'flex',
16
- icon,
17
- flow = 's',
18
- ...props
19
- }: AlertProps) {
12
+ export default function getAlertProps({ type = 'alert', keycolor, layout = 'flex', icon, flow = 's', ...props }: AlertProps) {
20
13
  const presetData = type ? PRESETS[type] : null;
21
14
  const _icon = icon || presetData?.icon || 'info';
22
15
  const _color = keycolor || presetData?.color || 'currentColor';
@@ -25,7 +18,7 @@ export default function getAlertProps({
25
18
  icon: _icon,
26
19
  layout,
27
20
  flow,
28
- lismClass: 'c--alert u-cbox',
21
+ lismClass: 'c--alert u--cbox',
29
22
  keycolor: _color,
30
23
  ai: 'center',
31
24
  p: '15',
@@ -18,7 +18,7 @@ export default function getCalloutProps({ type = 'note', keycolor, icon, title,
18
18
  icon: _icon,
19
19
  title,
20
20
  flow,
21
- lismClass: 'c--callout u-cbox',
21
+ lismClass: 'c--callout u--cbox',
22
22
  keycolor: _keycolor,
23
23
  p: '20',
24
24
  g: '10',
@@ -33,8 +33,8 @@ const { 'data-chat-dir': direction, ...chatProps } = getChatProps(inputProps);
33
33
  }
34
34
  {name && <Lism {...defaultProps.name}>{name}</Lism>}
35
35
  <Lism {...defaultProps.body}>
36
- <Decorator {...defaultProps.deco} class='u-cbox is--skipFlow' />
37
- <Flow {...defaultProps.content} class='u-cbox' flow={flow} jslf={direction}>
36
+ <Decorator {...defaultProps.deco} class='u--cbox is--skipFlow' />
37
+ <Flow {...defaultProps.content} class='u--cbox' flow={flow} jslf={direction}>
38
38
  <slot />
39
39
  </Flow>
40
40
  </Lism>
@@ -14,8 +14,8 @@ export default function Chat({ name, avatar, flow = 's', children, ...props }) {
14
14
  )}
15
15
  {name && <Lism {...defaultProps.name}>{name}</Lism>}
16
16
  <Lism {...defaultProps.body}>
17
- <Decorator {...defaultProps.deco} className='u-cbox is--skipFlow' />
18
- <Flow {...defaultProps.content} className='u-cbox' flow={flow} jslf={direction}>
17
+ <Decorator {...defaultProps.deco} className='u--cbox is--skipFlow' />
18
+ <Flow {...defaultProps.content} className='u--cbox' flow={flow} jslf={direction}>
19
19
  {children}
20
20
  </Flow>
21
21
  </Lism>
@@ -17,7 +17,7 @@ const btnProps = { ...defaultProps.closeBtn, ...props };
17
17
  ) : (
18
18
  <Lism data-modal-close={modalId} {...btnProps}>
19
19
  <Icon icon={icon || 'x'} />
20
- <span class='u-hidden'>{srText || 'Close'}</span>
20
+ <span class='u--srOnly'>{srText || 'Close'}</span>
21
21
  </Lism>
22
22
  )
23
23
  }
@@ -12,7 +12,7 @@ export default function CloseBtn({ children, modalId = '', icon, srText = 'Close
12
12
  ) : (
13
13
  <>
14
14
  <Icon icon={icon || 'x'} />
15
- <span className='u-hidden'>{srText || 'Close'}</span>
15
+ <span className='u--srOnly'>{srText || 'Close'}</span>
16
16
  </>
17
17
  )}
18
18
  </Lism>