@mirror-physics/fractal-ui 0.2.0-next.72 → 0.2.0-next.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.css CHANGED
@@ -859,6 +859,146 @@
859
859
  color: var(--error-default);
860
860
  }
861
861
 
862
+ /* src/components/Toast/Toast.css */
863
+ .fractal-toast-viewport {
864
+ position: fixed;
865
+ z-index: 10000;
866
+ display: flex;
867
+ width: min(400px, calc(100vw - var(--space-8, 32px)));
868
+ max-height: calc(100dvh - var(--space-8, 32px));
869
+ flex-direction: column;
870
+ gap: var(--space-2, 8px);
871
+ overflow: visible;
872
+ pointer-events: none;
873
+ }
874
+ .fractal-toast-viewport--top-center {
875
+ top: var(--space-4, 16px);
876
+ left: 50%;
877
+ align-items: center;
878
+ transform: translateX(-50%);
879
+ }
880
+ .fractal-toast-viewport--top-right {
881
+ top: var(--space-4, 16px);
882
+ right: var(--space-4, 16px);
883
+ align-items: flex-end;
884
+ }
885
+ .fractal-toast-viewport--bottom-center {
886
+ bottom: var(--space-4, 16px);
887
+ left: 50%;
888
+ align-items: center;
889
+ transform: translateX(-50%);
890
+ }
891
+ .fractal-toast {
892
+ display: flex;
893
+ box-sizing: border-box;
894
+ width: max-content;
895
+ max-width: 100%;
896
+ min-height: 40px;
897
+ align-items: center;
898
+ gap: var(--space-2, 8px);
899
+ padding: var(--space-1, 4px) var(--space-1, 4px) var(--space-1, 4px) var(--space-3, 12px);
900
+ border: 1px solid var(--border-default);
901
+ border-radius: var(--radius-full, 9999px);
902
+ background: var(--bg-canvas);
903
+ box-shadow: var(--shadow-md);
904
+ color: var(--fg-primary);
905
+ font-family: var(--font-sans);
906
+ font-size: 0.8125rem;
907
+ font-weight: 500;
908
+ line-height: 1.35;
909
+ pointer-events: auto;
910
+ animation: fractal-toast-in-from-top 180ms var(--ease-out, ease-out) both;
911
+ }
912
+ .fractal-toast-viewport--bottom-center .fractal-toast {
913
+ animation-name: fractal-toast-in-from-bottom;
914
+ }
915
+ .fractal-toast__icon {
916
+ display: grid;
917
+ width: 18px;
918
+ height: 18px;
919
+ flex: 0 0 18px;
920
+ place-items: center;
921
+ }
922
+ .fractal-toast--default .fractal-toast__icon {
923
+ color: var(--fg-secondary);
924
+ }
925
+ .fractal-toast--info .fractal-toast__icon {
926
+ color: var(--accent-default);
927
+ }
928
+ .fractal-toast--success .fractal-toast__icon {
929
+ color: var(--success-default);
930
+ }
931
+ .fractal-toast--warning .fractal-toast__icon {
932
+ color: var(--warning-default);
933
+ }
934
+ .fractal-toast--error .fractal-toast__icon {
935
+ color: var(--error-default);
936
+ }
937
+ .fractal-toast__content {
938
+ min-width: 0;
939
+ overflow-wrap: anywhere;
940
+ }
941
+ .fractal-toast__action {
942
+ display: flex;
943
+ flex: 0 0 auto;
944
+ align-items: center;
945
+ }
946
+ .fractal-toast__dismiss {
947
+ display: grid;
948
+ box-sizing: border-box;
949
+ width: 28px;
950
+ height: 28px;
951
+ flex: 0 0 28px;
952
+ padding: 0;
953
+ border: 0;
954
+ border-radius: var(--radius-full, 9999px);
955
+ background: transparent;
956
+ color: var(--fg-secondary);
957
+ cursor: pointer;
958
+ place-items: center;
959
+ }
960
+ .fractal-toast__dismiss:hover {
961
+ background: var(--hover-surface);
962
+ color: var(--fg-primary);
963
+ }
964
+ .fractal-toast__dismiss:focus-visible {
965
+ outline: 2px solid var(--border-focus);
966
+ outline-offset: -2px;
967
+ }
968
+ @keyframes fractal-toast-in-from-top {
969
+ from {
970
+ opacity: 0;
971
+ transform: translateY(-12px);
972
+ }
973
+ to {
974
+ opacity: 1;
975
+ transform: translateY(0);
976
+ }
977
+ }
978
+ @keyframes fractal-toast-in-from-bottom {
979
+ from {
980
+ opacity: 0;
981
+ transform: translateY(12px);
982
+ }
983
+ to {
984
+ opacity: 1;
985
+ transform: translateY(0);
986
+ }
987
+ }
988
+ @media (max-width: 640px) {
989
+ .fractal-toast-viewport {
990
+ width: calc(100vw - var(--space-6, 24px));
991
+ }
992
+ .fractal-toast-viewport--top-right {
993
+ right: var(--space-3, 12px);
994
+ }
995
+ }
996
+ @media (prefers-reduced-motion: reduce) {
997
+ .fractal-toast {
998
+ animation-duration: 0.01ms;
999
+ }
1000
+ }
1001
+
862
1002
  /* src/components/Toggle/Toggle.css */
863
1003
  .fractal-toggle {
864
1004
  display: inline-flex;
@@ -1576,23 +1716,8 @@
1576
1716
  background: var(--bg-surface-1);
1577
1717
  }
1578
1718
  .fractal-sortable-table-selection-cell {
1579
- position: relative;
1580
1719
  width: 52px;
1581
- min-width: 52px;
1582
- padding: 0 !important;
1583
- }
1584
- .fractal-sortable-table-selection-cell > .fractal-checkbox {
1585
- position: absolute;
1586
- inset: 0;
1587
- width: 100%;
1588
- height: 100%;
1589
- border-radius: 0;
1590
- }
1591
- .fractal-sortable-table-selection-cell > .fractal-checkbox:hover:not(:disabled) {
1592
- background: var(--hover-surface);
1593
- }
1594
- .fractal-sortable-table-selection-cell > .fractal-checkbox:focus-visible {
1595
- outline-offset: -2px;
1720
+ padding-right: 0 !important;
1596
1721
  }
1597
1722
  .fractal-sortable-table-td--row-action {
1598
1723
  position: relative;