@3birds/midori-ui 0.0.15 → 0.0.16

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/dist/alert.js CHANGED
@@ -1,15 +1,15 @@
1
1
  import { writable } from 'svelte/store';
2
- const initialState = {
2
+ const INITIAL_STATE = {
3
3
  show: false,
4
4
  message: '',
5
5
  type: 'info',
6
6
  duration: 3000
7
7
  };
8
- const { subscribe, set } = writable(initialState);
8
+ const { subscribe, set } = writable(INITIAL_STATE);
9
9
  export const alert = {
10
10
  subscribe,
11
11
  trigger: (message, type = 'info', duration = 3000) => {
12
12
  set({ show: true, message, type, duration });
13
13
  },
14
- close: () => set(initialState)
14
+ close: () => set(INITIAL_STATE)
15
15
  };
@@ -0,0 +1,7 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
2
+ <title>face-man</title>
3
+ <path
4
+ fill="currentColor"
5
+ d="M9,11.75A1.25,1.25 0 0,0 7.75,13A1.25,1.25 0 0,0 9,14.25A1.25,1.25 0 0,0 10.25,13A1.25,1.25 0 0,0 9,11.75M15,11.75A1.25,1.25 0 0,0 13.75,13A1.25,1.25 0 0,0 15,14.25A1.25,1.25 0 0,0 16.25,13A1.25,1.25 0 0,0 15,11.75M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M12,20C7.59,20 4,16.41 4,12C4,11.71 4,11.42 4.05,11.14C6.41,10.09 8.28,8.16 9.26,5.77C11.07,8.33 14.05,10 17.42,10C18.2,10 18.95,9.91 19.67,9.74C19.88,10.45 20,11.21 20,12C20,16.41 16.41,20 12,20Z"
6
+ />
7
+ </svg>
@@ -1,7 +1,7 @@
1
1
  <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
2
2
  <title>face-man</title>
3
3
  <path
4
- fill="currentColor"
4
+ fill="#e0f1e8"
5
5
  d="M9,11.75A1.25,1.25 0 0,0 7.75,13A1.25,1.25 0 0,0 9,14.25A1.25,1.25 0 0,0 10.25,13A1.25,1.25 0 0,0 9,11.75M15,11.75A1.25,1.25 0 0,0 13.75,13A1.25,1.25 0 0,0 15,14.25A1.25,1.25 0 0,0 16.25,13A1.25,1.25 0 0,0 15,11.75M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M12,20C7.59,20 4,16.41 4,12C4,11.71 4,11.42 4.05,11.14C6.41,10.09 8.28,8.16 9.26,5.77C11.07,8.33 14.05,10 17.42,10C18.2,10 18.95,9.91 19.67,9.74C19.88,10.45 20,11.21 20,12C20,16.41 16.41,20 12,20Z"
6
6
  />
7
7
  </svg>
@@ -36,7 +36,7 @@
36
36
 
37
37
  $effect(() => {
38
38
  if ($alert.show) {
39
- dialog?.showModal();
39
+ dialog?.show();
40
40
 
41
41
  setInterval(() => dialog?.close(), $alert.duration);
42
42
  } else {
@@ -49,12 +49,14 @@
49
49
  }
50
50
  </script>
51
51
 
52
- <dialog bind:this={dialog} onclose={handleClose} onclick={alert.close} class="modal">
52
+ <dialog
53
+ bind:this={dialog}
54
+ onclose={handleClose}
55
+ onclick={alert.close}
56
+ class="modal h-0 w-0 bg-transparent"
57
+ >
53
58
  <div class="fixed top-4 modal-box alert rounded-3xl {color} right-4 left-4" role="alert">
54
59
  <img src={icon} alt="アラート" class="size-6" />
55
60
  {$alert.message}
56
61
  </div>
57
- <form method="dialog" class="modal-backdrop">
58
- <button>close</button>
59
- </form>
60
62
  </dialog>
package/dist/index.d.ts CHANGED
@@ -17,6 +17,7 @@ export { default as deleteSvg } from './assets/delete.svg';
17
17
  export { default as emailOutlineSvg } from './assets/email-outline.svg';
18
18
  export { default as faceAgentSvg } from './assets/face-agent.svg';
19
19
  export { default as faceManSvg } from './assets/face-man.svg';
20
+ export { default as faceManWhiteSvg } from './assets/face-man-white.svg';
20
21
  export { default as faviconSvg } from './assets/favicon.svg';
21
22
  export { default as forestOutlineSvg } from './assets/forest-outline.svg';
22
23
  export { default as heartOutlineSvg } from './assets/heart-outline.svg';
package/dist/index.js CHANGED
@@ -18,6 +18,7 @@ export { default as deleteSvg } from './assets/delete.svg';
18
18
  export { default as emailOutlineSvg } from './assets/email-outline.svg';
19
19
  export { default as faceAgentSvg } from './assets/face-agent.svg';
20
20
  export { default as faceManSvg } from './assets/face-man.svg';
21
+ export { default as faceManWhiteSvg } from './assets/face-man-white.svg';
21
22
  export { default as faviconSvg } from './assets/favicon.svg';
22
23
  export { default as forestOutlineSvg } from './assets/forest-outline.svg';
23
24
  export { default as heartOutlineSvg } from './assets/heart-outline.svg';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@3birds/midori-ui",
3
- "version": "0.0.15",
3
+ "version": "0.0.16",
4
4
  "type": "module",
5
5
  "scripts": {
6
6
  "dev": "vite dev",