@mmb-digital/design-system-web 0.1.72 → 0.1.74

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/index.cjs.js CHANGED
@@ -212,6 +212,10 @@
212
212
  cursor: pointer;
213
213
  border: none;
214
214
  outline: none;
215
+ transition-timing-function: ease-in-out;
216
+ transition-timing-function: cubic-bezier(0.42, 0, 0.58, 1);
217
+ transition-duration: 0.2s;
218
+ transition-property: color, background-color, box-shadow;
215
219
 
216
220
  &:focus-visible {
217
221
  outline-width: 3px;
@@ -247,24 +251,24 @@
247
251
  `;case exports.ButtonStyle.SECONDARY:return t.css`
248
252
  color: ${({theme:e})=>n(e.colors.fg.neutral.subtle)} !important;
249
253
  background-color: transparent;
250
- box-shadow: inset 0 0 0 1px ${({theme:e})=>n(e.colors.border.neutral.subtle)};
254
+ box-shadow: 0 0 0 1px ${({theme:e})=>n(e.colors.border.neutral.subtle)};
251
255
 
252
256
  &:disabled {
253
257
  color: ${({theme:e})=>n(e.colors.fg.disabled)} !important;
254
258
  background-color: transparent;
255
- box-shadow: inset 0 0 0 1px solid ${({theme:e})=>n(e.colors.bg.disabled)};
259
+ box-shadow: 0 0 0 1px solid ${({theme:e})=>n(e.colors.bg.disabled)};
256
260
  }
257
261
 
258
262
  &:hover:not([disabled]) {
259
263
  color: ${({theme:e})=>n(e.colors.fg.brand.bold)} !important;
260
264
  background-color: ${({theme:e})=>n(e.colors.bg.brand.default)};
261
- box-shadow: inset 0 0 0 2px ${({theme:e})=>n(e.colors.border.brand.subtle)};
265
+ box-shadow: 0 0 0 2px ${({theme:e})=>n(e.colors.border.brand.subtle)};
262
266
  }
263
267
 
264
268
  &:active:not([disabled]) {
265
269
  color: ${({theme:e})=>n(e.colors.fg.brand.bold)} !important;
266
270
  background-color: ${({theme:e})=>n(e.colors.bg.brand.default.pressed)};
267
- box-shadow: inset 0 0 0 2px ${({theme:e})=>n(e.colors.border.brand.subtle)};
271
+ box-shadow: 0 0 0 2px ${({theme:e})=>n(e.colors.border.brand.subtle)};
268
272
  }
269
273
  `;case exports.ButtonStyle.TERTIARY:return t.css`
270
274
  color: ${({theme:e})=>n(e.colors.fg.neutral.subtle)} !important;
@@ -278,13 +282,13 @@
278
282
  &:hover:not([disabled]) {
279
283
  color: ${({theme:e})=>n(e.colors.fg.brand.bold)} !important;
280
284
  background-color: ${({theme:e})=>n(e.colors.bg.brand.default)};
281
- box-shadow: inset 0 0 0 2px ${({theme:e})=>n(e.colors.border.brand.subtle)};
285
+ box-shadow: 0 0 0 2px ${({theme:e})=>n(e.colors.border.brand.subtle)};
282
286
  }
283
287
 
284
288
  &:active:not([disabled]) {
285
289
  color: ${({theme:e})=>n(e.colors.fg.brand.bold)} !important;
286
290
  background-color: ${({theme:e})=>n(e.colors.bg.brand.default.pressed)};
287
- box-shadow: none;
291
+ box-shadow: 0 0 0 2px ${({theme:e})=>n(e.colors.bg.brand.default.pressed)};
288
292
  }
289
293
  `;default:return""}}}
290
294
 
@@ -1428,7 +1432,7 @@ function Gu(e,t,n){return t=qu(t),function(e,t){if(t&&("object"==typeof t||"func
1428
1432
  ::placeholder {
1429
1433
  color: ${({theme:e})=>e.palette.grey700};
1430
1434
  }
1431
- `,ip=t=>{const n=e.useRef(null),[r,o]=e.useState(void 0),a=Boolean(t)||0===t,i=e.useCallback((()=>{n.current&&o(n.current.offsetWidth)}),[]),s=qo(i,500,{maxWait:500});return e.useLayoutEffect((()=>{a&&i()}),[a,i]),e.useEffect((()=>(a&&window.addEventListener("resize",s),()=>{a&&window.removeEventListener("resize",s)})),[a,s]),{width:r,wrapperRef:n}},sp=e.forwardRef(((t,n)=>{const{button:r,colorInput:o,colorScheme:a=exports.ColorScheme.light,halfWidth:i,icon:s,id:l,maxLength:u,name:c,onBlur:d,onChange:p,onFocus:h,placeholder:f,prefix:m,prefixColor:g,size:b,suffix:v,weight:y=exports.InputWeight.REGULAR_400}=t,x=Ht(t,["button","colorInput","colorScheme","halfWidth","icon","id","maxLength","name","onBlur","onChange","onFocus","placeholder","prefix","prefixColor","size","suffix","weight"]),k=H(a),w=Ur([n,e.useRef(null)]),{width:C,wrapperRef:E}=ip(m),{width:I,wrapperRef:S}=ip(v);return e.createElement(Qd,{$halfWidth:i,$size:b},void 0!==s&&e.createElement(np,null,s),void 0!==m&&""!==m&&e.createElement(rp,{$chooseColor:k,$prefixColor:g,ref:E},m),e.createElement(tp,Object.assign({button:r,colorInput:o,halfWidth:i,icon:s,id:l,maxLength:u,name:c,placeholder:f,prefixWidth:C,ref:w,size:b,suffixWidth:I,weight:y,onBlur:d,onChange:p,onFocus:h},x)),void 0!==v&&""!==v&&e.createElement(ap,{ref:S},v),void 0!==r&&e.createElement(op,null,r))}));sp.displayName="InputBase";const lp=t.label`
1435
+ `,ip=(t,n)=>{const r=e.useRef(null),[o,a]=e.useState(void 0),i=Boolean(t)||0===t,s=e.useCallback((()=>{r.current&&a(r.current.offsetWidth)}),[]),l=qo(s,500,{maxWait:500});return e.useLayoutEffect((()=>{i&&s()}),[i,s]),e.useEffect((()=>{var e;return null===(e=n.current)||void 0===e||e.addEventListener("focus",s),()=>{var e;null===(e=n.current)||void 0===e||e.removeEventListener("focus",s)}}),[n,s]),e.useEffect((()=>(i&&window.addEventListener("resize",l),()=>{i&&window.removeEventListener("resize",l)})),[i,l]),{width:o,wrapperRef:r}},sp=e.forwardRef(((t,n)=>{const{button:r,colorInput:o,colorScheme:a=exports.ColorScheme.light,halfWidth:i,icon:s,id:l,maxLength:u,name:c,onBlur:d,onChange:p,onFocus:h,placeholder:f,prefix:m,prefixColor:g,size:b,suffix:v,weight:y=exports.InputWeight.REGULAR_400}=t,x=Ht(t,["button","colorInput","colorScheme","halfWidth","icon","id","maxLength","name","onBlur","onChange","onFocus","placeholder","prefix","prefixColor","size","suffix","weight"]),k=H(a),w=e.useRef(null),C=Ur([n,w]),{width:E,wrapperRef:I}=ip(m,w),{width:S,wrapperRef:T}=ip(v,w);return e.createElement(Qd,{$halfWidth:i,$size:b},void 0!==s&&e.createElement(np,null,s),void 0!==m&&""!==m&&e.createElement(rp,{$chooseColor:k,$prefixColor:g,ref:I},m),e.createElement(tp,Object.assign({button:r,colorInput:o,halfWidth:i,icon:s,id:l,maxLength:u,name:c,placeholder:f,prefixWidth:E,ref:C,size:b,suffixWidth:S,weight:y,onBlur:d,onChange:p,onFocus:h},x)),void 0!==v&&""!==v&&e.createElement(ap,{ref:T},v),void 0!==r&&e.createElement(op,null,r))}));sp.displayName="InputBase";const lp=t.label`
1432
1436
  display: flex;
1433
1437
  gap: ${({theme:e})=>e.spacing.xxs};
1434
1438
  align-items: center;