cynx-ui 1.2.30 → 1.2.32

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.
@@ -12,6 +12,8 @@ const STYLES = `
12
12
  animation: cx-toastSlide .18s ease;
13
13
  cursor: pointer;
14
14
  }
15
+ .toast.success { border-left: 3px solid var(--success, #27ae60); }
16
+ .toast.error { border-left: 3px solid var(--danger, #f64747); }
15
17
  .toast.ok { border-left: 3px solid var(--success, #27ae60); }
16
18
  .toast.err { border-left: 3px solid var(--danger, #f64747); }
17
19
  @keyframes cx-toastSlide { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: translateX(0); } }
@@ -75,7 +77,7 @@ export function Toast({ toasts, remove }) {
75
77
  <div id="toast-root">
76
78
  {toasts.map(t => (
77
79
  <div key={t.id} className={`toast ${t.type}`} onClick={() => remove(t.id)}>
78
- {t.type === 'ok'
80
+ {t.type === 'ok' || t.type === 'success'
79
81
  ? <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="var(--success)" strokeWidth="2.5" strokeLinecap="round"><polyline points="20 6 9 17 4 12"/></svg>
80
82
  : <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="var(--danger)" strokeWidth="2.5" strokeLinecap="round"><circle cx="12" cy="12" r="10"/><line x1="15" y1="9" x2="9" y2="15"/><line x1="9" y1="9" x2="15" y2="15"/></svg>
81
83
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cynx-ui",
3
- "version": "1.2.30",
3
+ "version": "1.2.32",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": "./index.js"