@uniai-fe/uds-primitives 0.3.4 → 0.3.6
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/styles.css +113 -0
- package/package.json +3 -2
- package/src/components/carousel/hooks/index.ts +2 -0
- package/src/components/carousel/hooks/useContext.ts +565 -0
- package/src/components/carousel/img/chevron-left.svg +3 -0
- package/src/components/carousel/img/chevron-right.svg +3 -0
- package/src/components/carousel/index.scss +1 -0
- package/src/components/carousel/index.tsx +6 -0
- package/src/components/carousel/markup/Container.tsx +54 -0
- package/src/components/carousel/markup/Control.tsx +53 -0
- package/src/components/carousel/markup/Provider.tsx +77 -0
- package/src/components/carousel/markup/Track.tsx +84 -0
- package/src/components/carousel/markup/button/Base.tsx +87 -0
- package/src/components/carousel/markup/button/Next.tsx +51 -0
- package/src/components/carousel/markup/button/Prev.tsx +53 -0
- package/src/components/carousel/markup/index.tsx +19 -0
- package/src/components/carousel/styles/carousel.scss +105 -0
- package/src/components/carousel/styles/index.scss +2 -0
- package/src/components/carousel/styles/variables.scss +16 -0
- package/src/components/carousel/types/index.ts +1 -0
- package/src/components/carousel/types/props.ts +372 -0
- package/src/components/carousel/utils/index.ts +1 -0
- package/src/components/carousel/utils/math.ts +62 -0
- package/src/components/table/styles/foundation.scss +1 -0
- package/src/components/table/styles/variables.scss +2 -0
- package/src/index.scss +1 -0
- package/src/index.tsx +1 -0
package/dist/styles.css
CHANGED
|
@@ -160,6 +160,19 @@
|
|
|
160
160
|
--color-surface-strong,
|
|
161
161
|
var(--color-cool-gray-20)
|
|
162
162
|
);
|
|
163
|
+
--carousel-gap: var(--spacing-gap-5);
|
|
164
|
+
--carousel-inside-button-offset: var(--spacing-padding-2);
|
|
165
|
+
--carousel-control-button-size: var(--theme-size-medium-2);
|
|
166
|
+
--carousel-control-button-active: var(--color-cool-gray-20);
|
|
167
|
+
--carousel-control-button-disabled: var(--color-cool-gray-85);
|
|
168
|
+
--carousel-control-button-z-index: 50;
|
|
169
|
+
--carousel-control-button-padding-inline: var(--spacing-padding-5);
|
|
170
|
+
--carousel-control-button-gap: var(--spacing-gap-2);
|
|
171
|
+
--carousel-control-button-label-padding-prev: var(--spacing-padding-7);
|
|
172
|
+
--carousel-control-button-label-padding-next: var(--spacing-padding-7);
|
|
173
|
+
--carousel-button-label-color: var(--color-common-100);
|
|
174
|
+
--carousel-button-label-disabled-color: var(--color-label-neutral);
|
|
175
|
+
--carousel-button-label-font-size: var(--font-label-medium-size);
|
|
163
176
|
--theme-checkbox-frame-size-medium: 20px;
|
|
164
177
|
--theme-checkbox-frame-size-large: 24px;
|
|
165
178
|
--theme-checkbox-indicator-size-medium: 16px;
|
|
@@ -509,6 +522,7 @@
|
|
|
509
522
|
);
|
|
510
523
|
--table-grid-row-highlight-background-color: rgba(229, 238, 255, 0.52);
|
|
511
524
|
--table-cell-background-color: var(--color-surface-static-white);
|
|
525
|
+
--table-cell-content-gap: var(--spacing-gap-2);
|
|
512
526
|
--table-line-cell-height-head: 44px;
|
|
513
527
|
--table-line-cell-height-body: 56px;
|
|
514
528
|
--table-grid-cell-height: 48px;
|
|
@@ -1410,6 +1424,104 @@
|
|
|
1410
1424
|
|
|
1411
1425
|
|
|
1412
1426
|
|
|
1427
|
+
.carousel-container {
|
|
1428
|
+
width: 100%;
|
|
1429
|
+
}
|
|
1430
|
+
|
|
1431
|
+
.carousel-control {
|
|
1432
|
+
width: 100%;
|
|
1433
|
+
display: flex;
|
|
1434
|
+
align-items: center;
|
|
1435
|
+
gap: var(--carousel-gap);
|
|
1436
|
+
}
|
|
1437
|
+
.carousel-control[data-button-placement=inside] {
|
|
1438
|
+
position: relative;
|
|
1439
|
+
gap: 0;
|
|
1440
|
+
}
|
|
1441
|
+
.carousel-control[data-button-placement=inside] .carousel-move-button {
|
|
1442
|
+
position: absolute;
|
|
1443
|
+
top: 50%;
|
|
1444
|
+
transform: translateY(-50%);
|
|
1445
|
+
}
|
|
1446
|
+
.carousel-control[data-button-placement=inside] .carousel-prev-button {
|
|
1447
|
+
left: var(--carousel-inside-button-offset);
|
|
1448
|
+
}
|
|
1449
|
+
.carousel-control[data-button-placement=inside] .carousel-next-button {
|
|
1450
|
+
right: var(--carousel-inside-button-offset);
|
|
1451
|
+
}
|
|
1452
|
+
|
|
1453
|
+
.carousel-viewport {
|
|
1454
|
+
width: 100%;
|
|
1455
|
+
flex: 1 1 auto;
|
|
1456
|
+
min-width: 0;
|
|
1457
|
+
overflow-x: auto;
|
|
1458
|
+
overflow-y: hidden;
|
|
1459
|
+
scroll-snap-type: x proximity;
|
|
1460
|
+
scrollbar-width: none;
|
|
1461
|
+
-ms-overflow-style: none;
|
|
1462
|
+
}
|
|
1463
|
+
.carousel-viewport::-webkit-scrollbar {
|
|
1464
|
+
display: none;
|
|
1465
|
+
}
|
|
1466
|
+
|
|
1467
|
+
.carousel-track {
|
|
1468
|
+
display: flex;
|
|
1469
|
+
gap: var(--carousel-gap);
|
|
1470
|
+
margin: 0;
|
|
1471
|
+
padding: 0;
|
|
1472
|
+
list-style: none;
|
|
1473
|
+
scroll-behavior: smooth;
|
|
1474
|
+
}
|
|
1475
|
+
.carousel-track > * {
|
|
1476
|
+
flex: 0 0 auto;
|
|
1477
|
+
scroll-snap-align: start;
|
|
1478
|
+
}
|
|
1479
|
+
|
|
1480
|
+
.carousel-item[data-carousel-focus=true] {
|
|
1481
|
+
z-index: 1;
|
|
1482
|
+
}
|
|
1483
|
+
|
|
1484
|
+
.carousel-move-button {
|
|
1485
|
+
min-width: var(--carousel-control-button-size);
|
|
1486
|
+
height: var(--carousel-control-button-size);
|
|
1487
|
+
border-radius: calc(var(--carousel-control-button-size) / 2);
|
|
1488
|
+
padding: 0 var(--carousel-control-button-padding-inline);
|
|
1489
|
+
display: flex;
|
|
1490
|
+
align-items: center;
|
|
1491
|
+
justify-content: center;
|
|
1492
|
+
gap: var(--carousel-control-button-gap);
|
|
1493
|
+
cursor: pointer;
|
|
1494
|
+
background: var(--carousel-control-button-active);
|
|
1495
|
+
z-index: var(--carousel-control-button-z-index);
|
|
1496
|
+
}
|
|
1497
|
+
.carousel-move-button:disabled {
|
|
1498
|
+
cursor: default;
|
|
1499
|
+
background: var(--carousel-control-button-disabled);
|
|
1500
|
+
}
|
|
1501
|
+
.carousel-move-button:disabled .carousel-button-label {
|
|
1502
|
+
color: var(--carousel-button-label-disabled-color);
|
|
1503
|
+
}
|
|
1504
|
+
.carousel-move-button.label-padding-prev {
|
|
1505
|
+
padding-right: var(--carousel-control-button-label-padding-prev);
|
|
1506
|
+
}
|
|
1507
|
+
.carousel-move-button.label-padding-next {
|
|
1508
|
+
padding-left: var(--carousel-control-button-label-padding-next);
|
|
1509
|
+
}
|
|
1510
|
+
|
|
1511
|
+
.carousel-move-button-icon {
|
|
1512
|
+
display: flex;
|
|
1513
|
+
margin: 0;
|
|
1514
|
+
}
|
|
1515
|
+
|
|
1516
|
+
.carousel-button-label {
|
|
1517
|
+
font-size: var(--carousel-button-label-font-size);
|
|
1518
|
+
font-weight: 400;
|
|
1519
|
+
line-height: 1em;
|
|
1520
|
+
color: var(--carousel-button-label-color);
|
|
1521
|
+
}
|
|
1522
|
+
|
|
1523
|
+
|
|
1524
|
+
|
|
1413
1525
|
.checkbox {
|
|
1414
1526
|
display: inline-flex;
|
|
1415
1527
|
align-items: center;
|
|
@@ -3983,6 +4095,7 @@ figure.chip {
|
|
|
3983
4095
|
height: 100%;
|
|
3984
4096
|
justify-content: flex-start;
|
|
3985
4097
|
box-sizing: border-box;
|
|
4098
|
+
gap: var(--table-cell-content-gap);
|
|
3986
4099
|
padding-inline: var(--table-cell-padding-inline);
|
|
3987
4100
|
padding-block: var(--table-cell-padding-block);
|
|
3988
4101
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uniai-fe/uds-primitives",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.6",
|
|
4
4
|
"description": "UNIAI Design System; Primitives Components Package",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"private": false,
|
|
@@ -53,7 +53,8 @@
|
|
|
53
53
|
"module:typecheck": "pnpm typecheck",
|
|
54
54
|
"module:build": "pnpm build",
|
|
55
55
|
"design-primitives:build": "pnpm run build",
|
|
56
|
-
"design-primitives:dev": "pnpm run dev"
|
|
56
|
+
"design-primitives:dev": "pnpm run dev",
|
|
57
|
+
"publish:public": "bash ../../../scripts/npm-publish.sh"
|
|
57
58
|
},
|
|
58
59
|
"peerDependencies": {
|
|
59
60
|
"@mantine/core": "^8",
|