@neo-design/foundations 1.0.0-rc.6 → 1.0.0-rc.7

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.
@@ -0,0 +1,138 @@
1
+ /* packages/foundations/css/bottom-sheet.css — emitted without comments. The reasoning behind each decision lives in Neo's source repository. */
2
+
3
+ .bottom-sheet {
4
+ position: fixed;
5
+ right: 0;
6
+ bottom: 0;
7
+ left: 0;
8
+ z-index: 1300;
9
+ display: flex;
10
+ flex-direction: column;
11
+ align-items: flex-start;
12
+ max-height: 90dvh;
13
+ background: var(--surface--base--default);
14
+ border-top-left-radius: var(--neo-radius-xl);
15
+ border-top-right-radius: var(--neo-radius-xl);
16
+ }
17
+
18
+
19
+ .bottom-sheet > * {
20
+ align-self: stretch;
21
+ }
22
+
23
+ .bottom-sheet__handle {
24
+ flex: 0 0 auto;
25
+ width: 40px;
26
+ height: 4px;
27
+ margin: var(--neo-space-sm-rem) auto;
28
+ border-radius: var(--neo-radius-pill);
29
+ background: var(--fill--base--medium);
30
+ }
31
+
32
+ .bottom-sheet__header {
33
+ flex: 0 0 auto;
34
+ display: flex;
35
+ flex-direction: column;
36
+ justify-content: center;
37
+ align-items: flex-end;
38
+ padding-inline: var(--neo-space-lg-rem);
39
+ padding-block: 0 var(--neo-space-xs-rem);
40
+ }
41
+
42
+ .bottom-sheet[data-scroll="top"] .bottom-sheet__header,
43
+ .bottom-sheet[data-scroll="mid"] .bottom-sheet__header,
44
+ .bottom-sheet[data-scroll="bottom"] .bottom-sheet__header {
45
+ border-bottom: var(--neo-stroke-xs) solid var(--border--base--secondary);
46
+ }
47
+
48
+ .bottom-sheet__header > * {
49
+ align-self: stretch;
50
+ }
51
+
52
+ .bottom-sheet__title-row {
53
+ display: flex;
54
+ align-items: center;
55
+ justify-content: flex-end;
56
+ height: 40px;
57
+ }
58
+
59
+ .bottom-sheet__title {
60
+ margin: 0;
61
+ flex: 1 1 auto;
62
+ min-width: 0;
63
+ overflow: hidden;
64
+ text-overflow: ellipsis;
65
+ white-space: nowrap;
66
+ color: var(--text--base--default);
67
+ font-size: var(--neo-type-body-lg-bold-size-rem);
68
+ font-weight: var(--neo-type-body-lg-bold-weight);
69
+ line-height: var(--neo-type-body-lg-bold-line-height-rem);
70
+ }
71
+
72
+ .bottom-sheet__header-image {
73
+ position: relative;
74
+ flex: 0 0 auto;
75
+ height: 160px;
76
+ overflow: hidden;
77
+ }
78
+
79
+ .bottom-sheet__header-image > img,
80
+ .bottom-sheet__header-image > picture,
81
+ .bottom-sheet__header-image > video {
82
+ display: block;
83
+ width: 100%;
84
+ height: 100%;
85
+ object-fit: cover;
86
+ }
87
+
88
+ .bottom-sheet__header-image .bottom-sheet__handle {
89
+ position: absolute;
90
+ right: 0;
91
+ left: 0;
92
+ top: 0;
93
+ background: var(--fill--base--default);
94
+ }
95
+
96
+ .bottom-sheet__header-image .bottom-sheet__close {
97
+ position: absolute;
98
+ top: var(--neo-space-lg-rem);
99
+ right: var(--neo-space-lg-rem);
100
+ }
101
+
102
+ .bottom-sheet__content {
103
+ flex: 1 1 auto;
104
+ overflow-y: auto;
105
+ min-height: 200px;
106
+ padding-inline: var(--neo-space-lg-rem);
107
+ padding-block: 0 var(--neo-space-lg-rem);
108
+ color: var(--text--base--default);
109
+ font-size: var(--neo-type-body-lg-regular-size-rem);
110
+ font-weight: var(--neo-type-body-lg-regular-weight);
111
+ line-height: var(--neo-type-body-lg-regular-line-height-rem);
112
+ }
113
+
114
+ .bottom-sheet__content:focus-visible {
115
+ outline: none;
116
+ box-shadow:
117
+ inset 0 0 0 var(--neo-stroke-focus-ring-width) var(--focus--ring--default),
118
+ inset 0 0 0 calc(var(--neo-stroke-focus-ring-width) * 2) var(--focus--gap--default);
119
+ }
120
+
121
+ .bottom-sheet__actions {
122
+ flex: 0 0 auto;
123
+ display: flex;
124
+ flex-direction: column;
125
+ gap: var(--neo-space-sm-rem);
126
+ padding-inline: var(--neo-space-lg-rem);
127
+ padding-block: var(--neo-space-lg-rem) var(--neo-space-2xl-rem);
128
+ background: var(--surface--base--default);
129
+ }
130
+
131
+ .bottom-sheet__actions .btn {
132
+ width: 100%;
133
+ }
134
+
135
+ .bottom-sheet__actions[data-scroll="top"],
136
+ .bottom-sheet__actions[data-scroll="mid"] {
137
+ border-top: var(--neo-stroke-xs) solid var(--border--base--secondary);
138
+ }
package/css/index.css CHANGED
@@ -4,6 +4,7 @@
4
4
  @import './aspect-ratio.css';
5
5
  @import './badge.css';
6
6
  @import './banner.css';
7
+ @import './bottom-sheet.css';
7
8
  @import './button.css';
8
9
  @import './button-icon.css';
9
10
  @import './checkbox.css';
@@ -26,10 +27,10 @@
26
27
  @import './tooltip.css';
27
28
 
28
29
  .alert, .aspect-ratio, .badge, .notification, .banner, .btn, .checkbox, .checkbox-group,
29
- .chip, .chips-group, .combobox, .empty-state, .empty-state-shell, .link, .menu-item, .menu-list, .menu-divider, .modal-overlay, .modal-dialog,
30
+ .bottom-sheet, .chip, .chips-group, .combobox, .empty-state, .empty-state-shell, .link, .menu-item, .menu-list, .menu-divider, .modal-overlay, .modal-dialog,
30
31
  .modal-full, .radio, .radio-group, .select, .snackbar, .spinner, .tabs, .tag, .field, .toggle, .tooltip,
31
32
  .alert *, .aspect-ratio *, .badge *, .banner *, .btn *, .checkbox *, .chip *, .combobox *,
32
- .empty-state *, .menu-item *, .menu-list *, .modal-dialog *, .modal-full *, .radio *, .select *, .snackbar *, .tabs *,
33
+ .bottom-sheet *, .empty-state *, .menu-item *, .menu-list *, .modal-dialog *, .modal-full *, .radio *, .select *, .snackbar *, .tabs *,
33
34
  .tag *, .field *, .toggle *, .tooltip *,
34
35
  [role="tablist"], [role="tab"] {
35
36
  box-sizing: border-box;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@neo-design/foundations",
3
- "version": "1.0.0-rc.6",
3
+ "version": "1.0.0-rc.7",
4
4
  "description": "Neo — the system foundations: semantic tokens in JS and CSS, icons and the plain CSS layer. It does not depend on React or Material UI.",
5
5
  "homepage": "https://github.com/jzamorano-ui/neo-ds/blob/main/docs/dev/INTEGRATION.md",
6
6
  "repository": {