cetec-design-system 1.2.1-next.0 → 1.2.1

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.
@@ -280,6 +280,27 @@ const keyframes = defineKeyframes({
280
280
  opacity: "0",
281
281
  transform: "translate(-50%, -50%) scale(0.95) translateY(-10px)"
282
282
  }
283
+ },
284
+ /** Top-aligned modal: horizontal center only (see modal recipe `position: top`) */
285
+ modalScaleInTop: {
286
+ "0%": {
287
+ opacity: "0",
288
+ transform: "translateX(-50%) scale(0.95) translateY(-10px)"
289
+ },
290
+ "100%": {
291
+ opacity: "1",
292
+ transform: "translateX(-50%) scale(1) translateY(0)"
293
+ }
294
+ },
295
+ modalScaleOutTop: {
296
+ "0%": {
297
+ opacity: "1",
298
+ transform: "translateX(-50%) scale(1) translateY(0)"
299
+ },
300
+ "100%": {
301
+ opacity: "0",
302
+ transform: "translateX(-50%) scale(0.95) translateY(-10px)"
303
+ }
283
304
  }
284
305
  });
285
306
  const fontVariants = {
@@ -7045,14 +7066,6 @@ const textInputBase = {
7045
7066
  borderColor: "border.input"
7046
7067
  }
7047
7068
  },
7048
- _readOnly: {
7049
- opacity: 0.4,
7050
- cursor: "not-allowed",
7051
- _focusWithin: {
7052
- outlineColor: "transparent",
7053
- borderColor: "border.input"
7054
- }
7055
- },
7056
7069
  _groupDisabled: {
7057
7070
  opacity: 1
7058
7071
  // let FormField handle disabled state opacity
@@ -7875,25 +7888,17 @@ const modalBase = {
7875
7888
  container: {
7876
7889
  ...globalBaseStyles,
7877
7890
  position: "fixed",
7878
- top: "50%",
7879
7891
  left: "50%",
7880
7892
  display: "flex",
7881
7893
  flexDirection: "column",
7882
7894
  width: "full",
7895
+ maxW: "95vw",
7883
7896
  maxHeight: "95vh",
7884
7897
  bg: "surface.overlay",
7885
7898
  borderRadius: "12",
7886
7899
  boxShadow: "overlay",
7887
7900
  outline: "none",
7888
- zIndex: 1101,
7889
- // Initial state matches animation start
7890
- opacity: "0",
7891
- transform: "translate(-50%, -50%) scale(0.95) translateY(-10px)",
7892
- // Animation handled via data-state
7893
- animation: "modalScaleIn 150ms ease-out forwards",
7894
- '&[data-state="closing"]': {
7895
- animation: "modalScaleOut 150ms ease-out forwards"
7896
- }
7901
+ zIndex: 1101
7897
7902
  },
7898
7903
  header: {
7899
7904
  display: "flex",
@@ -7931,31 +7936,39 @@ const modalBase = {
7931
7936
  borderTop: "default"
7932
7937
  }
7933
7938
  };
7939
+ const modalContainerCenteredOverlay = {
7940
+ top: "50%",
7941
+ transform: "translate(-50%, -50%) scale(0.95) translateY(-10px)",
7942
+ animation: "modalScaleIn 150ms ease-out forwards",
7943
+ '&[data-state="closing"]': {
7944
+ animation: "modalScaleOut 150ms ease-out forwards"
7945
+ }
7946
+ };
7934
7947
  const modalVariants = {
7935
7948
  size: {
7936
7949
  sm: {
7937
7950
  container: {
7938
- maxWidth: "md"
7951
+ w: "md"
7939
7952
  }
7940
7953
  },
7941
7954
  md: {
7942
7955
  container: {
7943
- maxWidth: "xl"
7956
+ w: "xl"
7944
7957
  }
7945
7958
  },
7946
7959
  lg: {
7947
7960
  container: {
7948
- maxWidth: "3xl"
7961
+ w: "3xl"
7949
7962
  }
7950
7963
  },
7951
7964
  xl: {
7952
7965
  container: {
7953
- maxWidth: "5xl"
7966
+ w: "5xl"
7954
7967
  }
7955
7968
  },
7956
7969
  full: {
7957
7970
  container: {
7958
- maxWidth: "95vw"
7971
+ w: "95vw"
7959
7972
  }
7960
7973
  },
7961
7974
  mobile: {
@@ -7968,6 +7981,24 @@ const modalVariants = {
7968
7981
  }
7969
7982
  }
7970
7983
  },
7984
+ position: {
7985
+ centered: {
7986
+ container: modalContainerCenteredOverlay
7987
+ },
7988
+ top: {
7989
+ container: {
7990
+ top: "min(2.5vh, token(spacing.64))",
7991
+ transform: "translate(-50%, 0) scale(0.95) translateY(-10px)",
7992
+ animation: "modalScaleInTop 150ms ease-out forwards",
7993
+ '&[data-state="closing"]': {
7994
+ animation: "modalScaleOutTop 150ms ease-out forwards"
7995
+ },
7996
+ // Align with default centered overlay at `xsDown` (full-viewport sheet):
7997
+ // without this, `top` + fixed offset leaves a gap above the sheet.
7998
+ xsDown: modalContainerCenteredOverlay
7999
+ }
8000
+ }
8001
+ },
7971
8002
  variant: {
7972
8003
  default: {
7973
8004
  container: {
@@ -8003,9 +8034,19 @@ const modalRecipe = defineSlotRecipe({
8003
8034
  ],
8004
8035
  base: modalBase,
8005
8036
  variants: modalVariants,
8037
+ compoundVariants: [
8038
+ {
8039
+ position: "top",
8040
+ size: "mobile",
8041
+ css: {
8042
+ container: modalContainerCenteredOverlay
8043
+ }
8044
+ }
8045
+ ],
8006
8046
  defaultVariants: {
8007
8047
  variant: "default",
8008
- size: "md"
8048
+ size: "md",
8049
+ position: "centered"
8009
8050
  }
8010
8051
  });
8011
8052
  const datePickerBase = {
@@ -9728,4 +9769,4 @@ export {
9728
9769
  breakpoints as b,
9729
9770
  containerSizes as c
9730
9771
  };
9731
- //# sourceMappingURL=cetec-preset-D4BY_Jqj.js.map
9772
+ //# sourceMappingURL=cetec-preset-D3bQHejk.js.map