1 | import {
|
2 | component_styles_default
|
3 | } from "./chunk.7IGWJVQF.js";
|
4 | import {
|
5 | r
|
6 | } from "./chunk.WWAD5WF4.js";
|
7 |
|
8 |
|
9 | var tab_group_styles_default = r`
|
10 | ${component_styles_default}
|
11 |
|
12 | :host {
|
13 | --indicator-color: var(--sl-color-primary-600);
|
14 | --track-color: var(--sl-color-neutral-200);
|
15 | --track-width: 2px;
|
16 |
|
17 | display: block;
|
18 | }
|
19 |
|
20 | .tab-group {
|
21 | display: flex;
|
22 | border: solid 1px transparent;
|
23 | border-radius: 0;
|
24 | }
|
25 |
|
26 | .tab-group .tab-group__tabs {
|
27 | display: flex;
|
28 | position: relative;
|
29 | }
|
30 |
|
31 | .tab-group .tab-group__indicator {
|
32 | position: absolute;
|
33 | transition: var(--sl-transition-fast) transform ease, var(--sl-transition-fast) width ease;
|
34 | }
|
35 |
|
36 | .tab-group--has-scroll-controls .tab-group__nav-container {
|
37 | position: relative;
|
38 | padding: 0 var(--sl-spacing-x-large);
|
39 | }
|
40 |
|
41 | .tab-group__scroll-button {
|
42 | display: flex;
|
43 | align-items: center;
|
44 | justify-content: center;
|
45 | position: absolute;
|
46 | top: 0;
|
47 | bottom: 0;
|
48 | width: var(--sl-spacing-x-large);
|
49 | }
|
50 |
|
51 | .tab-group__scroll-button--start {
|
52 | left: 0;
|
53 | }
|
54 |
|
55 | .tab-group__scroll-button--end {
|
56 | right: 0;
|
57 | }
|
58 |
|
59 | .tab-group--rtl .tab-group__scroll-button--start {
|
60 | left: auto;
|
61 | right: 0;
|
62 | }
|
63 |
|
64 | .tab-group--rtl .tab-group__scroll-button--end {
|
65 | left: 0;
|
66 | right: auto;
|
67 | }
|
68 |
|
69 | /*
|
70 | * Top
|
71 | */
|
72 |
|
73 | .tab-group--top {
|
74 | flex-direction: column;
|
75 | }
|
76 |
|
77 | .tab-group--top .tab-group__nav-container {
|
78 | order: 1;
|
79 | }
|
80 |
|
81 | .tab-group--top .tab-group__nav {
|
82 | display: flex;
|
83 | overflow-x: auto;
|
84 |
|
85 | /* Hide scrollbar in Firefox */
|
86 | scrollbar-width: none;
|
87 | }
|
88 |
|
89 | /* Hide scrollbar in Chrome/Safari */
|
90 | .tab-group--top .tab-group__nav::-webkit-scrollbar {
|
91 | width: 0;
|
92 | height: 0;
|
93 | }
|
94 |
|
95 | .tab-group--top .tab-group__tabs {
|
96 | flex: 1 1 auto;
|
97 | position: relative;
|
98 | flex-direction: row;
|
99 | border-bottom: solid var(--track-width) var(--track-color);
|
100 | }
|
101 |
|
102 | .tab-group--top .tab-group__indicator {
|
103 | bottom: calc(-1 * var(--track-width));
|
104 | border-bottom: solid var(--track-width) var(--indicator-color);
|
105 | }
|
106 |
|
107 | .tab-group--top .tab-group__body {
|
108 | order: 2;
|
109 | }
|
110 |
|
111 | .tab-group--top ::slotted(sl-tab-panel) {
|
112 | --padding: var(--sl-spacing-medium) 0;
|
113 | }
|
114 |
|
115 | /*
|
116 | * Bottom
|
117 | */
|
118 |
|
119 | .tab-group--bottom {
|
120 | flex-direction: column;
|
121 | }
|
122 |
|
123 | .tab-group--bottom .tab-group__nav-container {
|
124 | order: 2;
|
125 | }
|
126 |
|
127 | .tab-group--bottom .tab-group__nav {
|
128 | display: flex;
|
129 | overflow-x: auto;
|
130 |
|
131 | /* Hide scrollbar in Firefox */
|
132 | scrollbar-width: none;
|
133 | }
|
134 |
|
135 | /* Hide scrollbar in Chrome/Safari */
|
136 | .tab-group--bottom .tab-group__nav::-webkit-scrollbar {
|
137 | width: 0;
|
138 | height: 0;
|
139 | }
|
140 |
|
141 | .tab-group--bottom .tab-group__tabs {
|
142 | flex: 1 1 auto;
|
143 | position: relative;
|
144 | flex-direction: row;
|
145 | border-top: solid var(--track-width) var(--track-color);
|
146 | }
|
147 |
|
148 | .tab-group--bottom .tab-group__indicator {
|
149 | top: calc(-1 * var(--track-width));
|
150 | border-top: solid var(--track-width) var(--indicator-color);
|
151 | }
|
152 |
|
153 | .tab-group--bottom .tab-group__body {
|
154 | order: 1;
|
155 | }
|
156 |
|
157 | .tab-group--bottom ::slotted(sl-tab-panel) {
|
158 | --padding: var(--sl-spacing-medium) 0;
|
159 | }
|
160 |
|
161 | /*
|
162 | * Start
|
163 | */
|
164 |
|
165 | .tab-group--start {
|
166 | flex-direction: row;
|
167 | }
|
168 |
|
169 | .tab-group--start .tab-group__nav-container {
|
170 | order: 1;
|
171 | }
|
172 |
|
173 | .tab-group--start .tab-group__tabs {
|
174 | flex: 0 0 auto;
|
175 | flex-direction: column;
|
176 | border-inline-end: solid var(--track-width) var(--track-color);
|
177 | }
|
178 |
|
179 | .tab-group--start .tab-group__indicator {
|
180 | right: calc(-1 * var(--track-width));
|
181 | border-right: solid var(--track-width) var(--indicator-color);
|
182 | }
|
183 |
|
184 | .tab-group--start.tab-group--rtl .tab-group__indicator {
|
185 | right: auto;
|
186 | left: calc(-1 * var(--track-width));
|
187 | }
|
188 |
|
189 | .tab-group--start .tab-group__body {
|
190 | flex: 1 1 auto;
|
191 | order: 2;
|
192 | }
|
193 |
|
194 | .tab-group--start ::slotted(sl-tab-panel) {
|
195 | --padding: 0 var(--sl-spacing-medium);
|
196 | }
|
197 |
|
198 | /*
|
199 | * End
|
200 | */
|
201 |
|
202 | .tab-group--end {
|
203 | flex-direction: row;
|
204 | }
|
205 |
|
206 | .tab-group--end .tab-group__nav-container {
|
207 | order: 2;
|
208 | }
|
209 |
|
210 | .tab-group--end .tab-group__tabs {
|
211 | flex: 0 0 auto;
|
212 | flex-direction: column;
|
213 | border-right: solid var(--track-width) var(--track-color);
|
214 | }
|
215 |
|
216 | .tab-group--end .tab-group__indicator {
|
217 | left: calc(-1 * var(--track-width));
|
218 | border-inline-start: solid var(--track-width) var(--indicator-color);
|
219 | }
|
220 |
|
221 | .tab-group--end.tab-group--rtl .tab-group__indicator {
|
222 | right: calc(-1 * var(--track-width));
|
223 | left: auto;
|
224 | }
|
225 |
|
226 | .tab-group--end .tab-group__body {
|
227 | flex: 1 1 auto;
|
228 | order: 1;
|
229 | }
|
230 |
|
231 | .tab-group--end ::slotted(sl-tab-panel) {
|
232 | --padding: 0 var(--sl-spacing-medium);
|
233 | }
|
234 | `;
|
235 |
|
236 | export {
|
237 | tab_group_styles_default
|
238 | };
|