@rogieking/figui3 2.0.7 → 2.0.9
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/components.css +382 -56
- package/example.html +337 -76
- package/fig.js +1763 -68
- package/package.json +1 -1
- package/end-point-line.svg +0 -3
- package/end-points.zip +0 -0
package/components.css
CHANGED
|
@@ -294,6 +294,14 @@
|
|
|
294
294
|
--icon-chevron: url("data:image/svg+xml,%3Csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5.87868 7.12132L8 9.24264L10.1213 7.12132' stroke='black' stroke-linecap='round'/%3E%3C/svg%3E%0A");
|
|
295
295
|
--icon-checkmark: url("data:image/svg+xml,%3Csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M11.7773 4.08403C12.0071 4.2372 12.0692 4.54764 11.916 4.7774L7.91603 10.7774C7.83293 10.902 7.69834 10.9829 7.54927 10.9976C7.4002 11.0124 7.25237 10.9595 7.14645 10.8536L4.14645 7.85361C3.95118 7.65834 3.95118 7.34176 4.14645 7.1465C4.34171 6.95124 4.65829 6.95124 4.85355 7.1465L7.42229 9.71523L11.084 4.2227C11.2372 3.99294 11.5476 3.93085 11.7773 4.08403Z' fill='white'/%3E%3C/svg%3E%0A");
|
|
296
296
|
--icon-steppers: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11.7245 6.08191C11.9186 5.95386 12.1826 5.97562 12.3534 6.14637L14.3534 8.14637L14.4179 8.22449C14.546 8.41852 14.5242 8.68253 14.3534 8.8534C14.1826 9.02426 13.9186 9.04601 13.7245 8.91785L13.6464 8.8534L11.9999 7.20691L10.3534 8.8534C10.1582 9.04866 9.84166 9.04866 9.6464 8.8534C9.45123 8.65813 9.45117 8.3416 9.6464 8.14637L11.6464 6.14637L11.7245 6.08191Z' fill='black'/%3E%3Cpath d='M13.7248 15.0822C13.9189 14.9541 14.1829 14.9758 14.3537 15.1467C14.5246 15.3176 14.5463 15.5815 14.4182 15.7756L14.3537 15.8537L12.3537 17.8537C12.1829 18.0246 11.9189 18.0463 11.7248 17.9182L11.6467 17.8537L9.64669 15.8537L9.58224 15.7756C9.45407 15.5815 9.47583 15.3176 9.64669 15.1467C9.81756 14.9758 10.0815 14.9541 10.2756 15.0822L10.3537 15.1467L12.0002 16.7932L13.6467 15.1467L13.7248 15.0822Z' fill='black' /%3E%3C/svg%3E%0A");
|
|
297
|
+
--icon-eyedropper: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M15.1592 5.65801C16.0376 4.78045 17.4621 4.78055 18.3408 5.65899L18.4951 5.82989C19.1671 6.65442 19.168 7.84476 18.4951 8.66973L18.3408 8.84063L16.6455 10.533C17.1104 11.083 17.1181 11.889 16.6641 12.4461L16.5605 12.5604C16.0111 13.1097 15.1425 13.1428 14.5537 12.6629L14.5342 12.6453L10.0908 17.0916C9.6188 17.5633 8.98876 17.7764 8.375 17.742L7.56055 18.5574C6.97441 19.1432 6.02451 19.1422 5.43945 18.5584V18.5574C4.8538 17.9718 4.85405 17.0221 5.43945 16.4363L6.25586 15.618C6.22412 15.0058 6.44026 14.3794 6.90918 13.91L11.3516 9.46367C10.856 8.87434 10.885 7.99381 11.4395 7.43926L11.5537 7.33574C12.1094 6.88283 12.9136 6.88854 13.4639 7.35137L15.1592 5.65801ZM7.61621 14.617C7.33755 14.8961 7.21782 15.2747 7.25781 15.6385C7.27925 15.8351 7.24419 16.0445 7.10449 16.1844L6.14648 17.1434C5.9516 17.3387 5.95135 17.6553 6.14648 17.8504C6.34167 18.0449 6.65842 18.0451 6.85352 17.8504L7.80859 16.8943C7.94931 16.7536 8.16065 16.7184 8.3584 16.741C8.72329 16.7828 9.10374 16.6643 9.38379 16.3846L13.8223 11.9432L12.0547 10.1756L7.61621 14.617ZM17.6338 6.36602C17.1458 5.87828 16.3544 5.8783 15.8662 6.36602L14.084 8.14629L14.0186 8.20586C13.6767 8.48476 13.1722 8.46484 12.8535 8.14629C12.6583 7.95131 12.3417 7.95119 12.1465 8.14629C11.9514 8.34148 11.9515 8.65808 12.1465 8.85332L15.1465 11.8533C15.3175 12.024 15.5814 12.0451 15.7754 11.9168L15.8535 11.8533C16.0486 11.6582 16.0484 11.3416 15.8535 11.1463V11.1453C15.8524 11.1443 15.8507 11.1434 15.8496 11.1424C15.5128 10.8013 15.514 10.2513 15.8535 9.91192L17.6338 8.1336C18.1216 7.6457 18.1213 6.85425 17.6338 6.36602Z' fill='black' fill-opacity='0.9'/%3E%3C/svg%3E");
|
|
298
|
+
--icon-add: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M12 6C12.2761 6 12.5 6.22386 12.5 6.5V11.5H17.5C17.7761 11.5 18 11.7239 18 12C18 12.2761 17.7761 12.5 17.5 12.5H12.5V17.5C12.5 17.7761 12.2761 18 12 18C11.7239 18 11.5 17.7761 11.5 17.5V12.5H6.5C6.22386 12.5 6 12.2761 6 12C6 11.7239 6.22386 11.5 6.5 11.5H11.5V6.5C11.5 6.22386 11.7239 6 12 6Z' fill='currentColor'/%3E%3C/svg%3E");
|
|
299
|
+
--icon-minus: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M18 12C18 12.2761 17.7761 12.5 17.5 12.5H6.5C6.22386 12.5 6 12.2761 6 12C6 11.7239 6.22386 11.5 6.5 11.5H17.5C17.7761 11.5 18 11.7239 18 12Z' fill='currentColor'/%3E%3C/svg%3E");
|
|
300
|
+
--icon-back: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M13.8536 7.14645C14.0488 7.34171 14.0488 7.65829 13.8536 7.85355L9.70711 12L13.8536 16.1464C14.0488 16.3417 14.0488 16.6583 13.8536 16.8536C13.6583 17.0488 13.3417 17.0488 13.1464 16.8536L8.64645 12.3535C8.55268 12.2598 8.5 12.1326 8.5 12C8.5 11.8674 8.55268 11.7402 8.64645 11.6464L13.1464 7.14645C13.3417 6.95118 13.6583 6.95118 13.8536 7.14645Z' fill='currentColor'/%3E%3C/svg%3E");
|
|
301
|
+
--icon-forward: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M10.1464 16.8536C9.95118 16.6583 9.95118 16.3417 10.1464 16.1464L14.2929 12L10.1464 7.85355C9.95118 7.65829 9.95118 7.34171 10.1464 7.14645C10.3417 6.95118 10.6583 6.95118 10.8536 7.14645L15.3536 11.6464C15.5488 11.8417 15.5488 12.1583 15.3536 12.3536L10.8536 16.8536C10.6583 17.0488 10.3417 17.0488 10.1464 16.8536Z' fill='currentColor'/%3E%3C/svg%3E");
|
|
302
|
+
--icon-close: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M16.2242 7.08154C16.4182 6.95348 16.6823 6.97551 16.8531 7.146C17.024 7.31683 17.0457 7.58084 16.9176 7.7749L16.8531 7.85303L12.7067 11.9995L16.8531 16.146L16.9176 16.2241C17.0457 16.4182 17.024 16.6822 16.8531 16.853C16.6823 17.0239 16.4183 17.0456 16.2242 16.9175L16.1461 16.853L11.9996 12.7065L7.85315 16.853C7.65789 17.0483 7.34138 17.0483 7.14612 16.853C6.95128 16.6577 6.95101 16.3411 7.14612 16.146L11.2926 11.9995L7.14612 7.85303L7.08167 7.7749C6.95389 7.58087 6.97541 7.3167 7.14612 7.146C7.31683 6.97532 7.58101 6.95376 7.77502 7.08154L7.85315 7.146L11.9996 11.2925L16.1461 7.146L16.2242 7.08154Z' fill='currentColor'/%3E%3C/svg%3E");
|
|
303
|
+
--icon-rotate: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M10.2325 6.47442C11.2088 5.49811 12.7917 5.49811 13.768 6.47442L15.2931 7.99955H14.0002C13.7241 7.99955 13.5002 8.2234 13.5002 8.49955C13.5002 8.77569 13.7241 8.99955 14.0002 8.99955H16.5002C16.7764 8.99955 17.0002 8.77569 17.0002 8.49955V5.99955C17.0002 5.7234 16.7764 5.49955 16.5002 5.49955C16.2241 5.49955 16.0002 5.7234 16.0002 5.99955V7.29244L14.4751 5.76731C13.1083 4.40048 10.8922 4.40048 9.52537 5.76731L7.14669 8.14599C6.95143 8.34126 6.95143 8.65784 7.14669 8.8531C7.34195 9.04836 7.65854 9.04836 7.8538 8.8531L10.2325 6.47442ZM13.0609 9.64599C12.4751 9.06021 11.5254 9.06021 10.9396 9.64599L7.64669 12.9389C7.06091 13.5247 7.0609 14.4744 7.64669 15.0602L10.9396 18.3531C11.5254 18.9389 12.4751 18.9389 13.0609 18.3531L16.3538 15.0602C16.9396 14.4744 16.9396 13.5247 16.3538 12.9389L13.0609 9.64599ZM11.6467 10.3531C11.842 10.1578 12.1585 10.1578 12.3538 10.3531L15.6467 13.646C15.842 13.8413 15.842 14.1578 15.6467 14.3531L12.3538 17.646C12.1585 17.8413 11.842 17.8413 11.6467 17.646L8.3538 14.3531C8.15854 14.1578 8.15854 13.8413 8.3538 13.646L11.6467 10.3531Z' fill='currentColor'/%3E%3C/svg%3E");
|
|
304
|
+
--icon-swap: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M8.35355 6.35355C8.54882 6.15829 8.54882 5.84171 8.35355 5.64645C8.15829 5.45118 7.84171 5.45118 7.64645 5.64645L5.14645 8.14645C4.95118 8.34171 4.95118 8.65829 5.14645 8.85355L7.64645 11.3536C7.84171 11.5488 8.15829 11.5488 8.35355 11.3536C8.54882 11.1583 8.54882 10.8417 8.35355 10.6464L6.70711 9H18.5C18.7761 9 19 8.77614 19 8.5C19 8.22386 18.7761 8 18.5 8H6.70711L8.35355 6.35355ZM15.6464 13.3536C15.4512 13.1583 15.4512 12.8417 15.6464 12.6464C15.8417 12.4512 16.1583 12.4512 16.3536 12.6464L18.8536 15.1464C19.0488 15.3417 19.0488 15.6583 18.8536 15.8536L16.3536 18.3536C16.1583 18.5488 15.8417 18.5488 15.6464 18.3536C15.4512 18.1583 15.4512 17.8417 15.6464 17.6464L17.2929 16H5.5C5.22386 16 5 15.7761 5 15.5C5 15.2239 5.22386 15 5.5 15H17.2929L15.6464 13.3536Z' fill='currentColor'/%3E%3C/svg%3E");
|
|
297
305
|
|
|
298
306
|
/* Elevations - light theme defaults */
|
|
299
307
|
--elevation-500-modal-window: 0px 0px 0.5px rgba(0, 0, 0, 0.08),
|
|
@@ -739,6 +747,7 @@ fig-button {
|
|
|
739
747
|
|
|
740
748
|
/* Variant: Overlay (for on top of content) */
|
|
741
749
|
&[variant="overlay"] {
|
|
750
|
+
color-scheme: light;
|
|
742
751
|
background-color: var(--figma-color-bg);
|
|
743
752
|
color: var(--figma-color-text);
|
|
744
753
|
box-shadow: 0 0 0 1px var(--figma-color-bordertranslucent);
|
|
@@ -1068,9 +1077,11 @@ input[type="color"] {
|
|
|
1068
1077
|
}
|
|
1069
1078
|
|
|
1070
1079
|
fig-chit {
|
|
1071
|
-
--gradient-color-1: #ff90ff;
|
|
1072
|
-
--gradient-color-2: #0000ff;
|
|
1073
1080
|
--size: 1.5rem;
|
|
1081
|
+
--chit-background: #d9d9d9;
|
|
1082
|
+
--chit-bg-size: cover;
|
|
1083
|
+
--chit-bg-position: center;
|
|
1084
|
+
|
|
1074
1085
|
display: inline-grid;
|
|
1075
1086
|
width: var(--size);
|
|
1076
1087
|
height: var(--size);
|
|
@@ -1082,6 +1093,7 @@ fig-chit {
|
|
|
1082
1093
|
grid-area: 1/1;
|
|
1083
1094
|
}
|
|
1084
1095
|
|
|
1096
|
+
/* Selection ring */
|
|
1085
1097
|
&[selected]:not([selected="false"])::before {
|
|
1086
1098
|
content: "";
|
|
1087
1099
|
width: var(--size);
|
|
@@ -1094,19 +1106,14 @@ fig-chit {
|
|
|
1094
1106
|
&[size="large"] {
|
|
1095
1107
|
--size: 1.75rem;
|
|
1096
1108
|
|
|
1097
|
-
|
|
1098
|
-
&[type="image"]::after,
|
|
1099
|
-
&[type="color"]::after,
|
|
1109
|
+
/* Large size: swatch fills the whole area */
|
|
1100
1110
|
input[type="color"] {
|
|
1101
1111
|
padding: 0;
|
|
1102
1112
|
width: var(--size);
|
|
1103
1113
|
height: var(--size);
|
|
1104
1114
|
border-radius: var(--radius-medium);
|
|
1105
1115
|
}
|
|
1106
|
-
|
|
1107
|
-
box-shadow: inset 0 0 0 1px var(--figma-color-border-selected),
|
|
1108
|
-
inset 0 0 0 3px var(--figma-color-bg);
|
|
1109
|
-
}
|
|
1116
|
+
|
|
1110
1117
|
input[type="color"]::-webkit-color-swatch-wrapper {
|
|
1111
1118
|
border-radius: var(--radius-medium);
|
|
1112
1119
|
}
|
|
@@ -1118,76 +1125,71 @@ fig-chit {
|
|
|
1118
1125
|
input[type="color"]::-moz-color-swatch {
|
|
1119
1126
|
border-radius: var(--radius-medium);
|
|
1120
1127
|
}
|
|
1121
|
-
}
|
|
1122
1128
|
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1129
|
+
&[selected]:not([selected="false"])::before {
|
|
1130
|
+
box-shadow: inset 0 0 0 1px var(--figma-color-border-selected),
|
|
1131
|
+
inset 0 0 0 3px var(--figma-color-bg);
|
|
1132
|
+
}
|
|
1133
|
+
|
|
1134
|
+
/* Large gradient/image: also fill the area */
|
|
1135
|
+
&[data-type="gradient"]::after,
|
|
1136
|
+
&[data-type="image"]::after {
|
|
1137
|
+
width: var(--size);
|
|
1138
|
+
height: var(--size);
|
|
1139
|
+
border-radius: var(--radius-medium);
|
|
1126
1140
|
}
|
|
1127
1141
|
}
|
|
1128
1142
|
|
|
1129
|
-
&[
|
|
1130
|
-
|
|
1143
|
+
&[disabled] {
|
|
1144
|
+
pointer-events: none;
|
|
1145
|
+
opacity: 0.5;
|
|
1146
|
+
}
|
|
1147
|
+
|
|
1148
|
+
/* Gradient/Image types - inset thumbnail with hidden input */
|
|
1149
|
+
&[data-type="gradient"],
|
|
1150
|
+
&[data-type="image"] {
|
|
1151
|
+
background-color: var(--figma-color-bg-secondary);
|
|
1152
|
+
|
|
1131
1153
|
&::after {
|
|
1132
1154
|
content: "";
|
|
1133
1155
|
width: 0.875rem;
|
|
1134
1156
|
height: 0.875rem;
|
|
1135
|
-
background
|
|
1157
|
+
background: var(--chit-background);
|
|
1158
|
+
background-size: var(--chit-bg-size);
|
|
1159
|
+
background-position: var(--chit-bg-position);
|
|
1160
|
+
background-repeat: repeat;
|
|
1136
1161
|
border-radius: 0.125rem;
|
|
1137
|
-
background-size: contain;
|
|
1138
|
-
background-position: center center;
|
|
1139
|
-
background-repeat: no-repeat;
|
|
1140
1162
|
box-shadow: inset 0 0 0 1px var(--figma-color-bordertranslucent);
|
|
1141
1163
|
}
|
|
1164
|
+
|
|
1142
1165
|
&::after,
|
|
1143
1166
|
input {
|
|
1144
1167
|
grid-area: 1/1;
|
|
1145
1168
|
place-self: center;
|
|
1146
1169
|
}
|
|
1170
|
+
|
|
1147
1171
|
input[type="color"] {
|
|
1148
1172
|
opacity: 0;
|
|
1149
1173
|
}
|
|
1174
|
+
|
|
1150
1175
|
input[type="color"]::-webkit-color-swatch-wrapper {
|
|
1151
1176
|
background: none;
|
|
1152
1177
|
}
|
|
1178
|
+
|
|
1153
1179
|
input[type="color"]::-moz-color-swatch {
|
|
1154
1180
|
opacity: 0;
|
|
1155
1181
|
}
|
|
1182
|
+
|
|
1156
1183
|
input[type="color"]::-webkit-color-swatch {
|
|
1157
1184
|
opacity: 0;
|
|
1158
1185
|
}
|
|
1159
1186
|
}
|
|
1160
1187
|
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
&[type="gradient"] {
|
|
1167
|
-
&[variant="linear"]::after {
|
|
1168
|
-
--gradient: linear-gradient(
|
|
1169
|
-
to bottom,
|
|
1170
|
-
var(--gradient-color-1),
|
|
1171
|
-
var(--gradient-color-2)
|
|
1172
|
-
);
|
|
1173
|
-
}
|
|
1174
|
-
&[variant="angular"]::after {
|
|
1175
|
-
--gradient: conic-gradient(
|
|
1176
|
-
from 180deg,
|
|
1177
|
-
var(--gradient-color-1),
|
|
1178
|
-
var(--gradient-color-2)
|
|
1179
|
-
);
|
|
1180
|
-
}
|
|
1181
|
-
&[variant="radial"]::after {
|
|
1182
|
-
--gradient: radial-gradient(
|
|
1183
|
-
circle,
|
|
1184
|
-
var(--gradient-color-1),
|
|
1185
|
-
var(--gradient-color-2)
|
|
1186
|
-
);
|
|
1187
|
-
}
|
|
1188
|
-
&::after {
|
|
1189
|
-
background: var(--gradient);
|
|
1190
|
-
}
|
|
1188
|
+
/* Checkerboard for empty/missing images */
|
|
1189
|
+
&[data-type="image"]:not([background])::after,
|
|
1190
|
+
&[data-type="image"][background=""]::after,
|
|
1191
|
+
&[data-type="image"][background="url()"]::after {
|
|
1192
|
+
background: var(--checkerboard);
|
|
1191
1193
|
}
|
|
1192
1194
|
}
|
|
1193
1195
|
|
|
@@ -1204,6 +1206,9 @@ fig-image {
|
|
|
1204
1206
|
}
|
|
1205
1207
|
fig-chit {
|
|
1206
1208
|
--size: var(--image-size) !important;
|
|
1209
|
+
&[disabled] {
|
|
1210
|
+
opacity: 1;
|
|
1211
|
+
}
|
|
1207
1212
|
}
|
|
1208
1213
|
&:not([src]):not([src=""]) fig-button,
|
|
1209
1214
|
&:hover fig-button {
|
|
@@ -1219,9 +1224,7 @@ fig-image {
|
|
|
1219
1224
|
&[aspect-ratio="auto"] {
|
|
1220
1225
|
aspect-ratio: var(--aspect-ratio);
|
|
1221
1226
|
height: auto;
|
|
1222
|
-
fig-chit
|
|
1223
|
-
fig-chit::after,
|
|
1224
|
-
input {
|
|
1227
|
+
fig-chit {
|
|
1225
1228
|
height: auto !important;
|
|
1226
1229
|
aspect-ratio: var(--aspect-ratio) !important;
|
|
1227
1230
|
}
|
|
@@ -1255,14 +1258,14 @@ fig-image {
|
|
|
1255
1258
|
gap: 1px;
|
|
1256
1259
|
|
|
1257
1260
|
& > * {
|
|
1258
|
-
&:first-child,
|
|
1259
|
-
&:first-child > * {
|
|
1261
|
+
&:first-child:not(:last-child),
|
|
1262
|
+
&:first-child:not(:last-child) > * {
|
|
1260
1263
|
border-top-right-radius: 0;
|
|
1261
1264
|
border-bottom-right-radius: 0;
|
|
1262
1265
|
}
|
|
1263
1266
|
|
|
1264
|
-
&:last-child,
|
|
1265
|
-
&:last-child > * {
|
|
1267
|
+
&:last-child:not(:first-child),
|
|
1268
|
+
&:last-child:not(:first-child) > * {
|
|
1266
1269
|
border-top-left-radius: 0;
|
|
1267
1270
|
border-bottom-left-radius: 0;
|
|
1268
1271
|
}
|
|
@@ -2348,12 +2351,20 @@ fig-input-color {
|
|
|
2348
2351
|
text-transform: uppercase;
|
|
2349
2352
|
}
|
|
2350
2353
|
}
|
|
2354
|
+
& fig-chit:not(:only-child),
|
|
2355
|
+
& fig-chit:not(:only-child) > input {
|
|
2356
|
+
border-top-right-radius: 0 !important;
|
|
2357
|
+
border-bottom-right-radius: 0 !important;
|
|
2358
|
+
}
|
|
2351
2359
|
|
|
2352
2360
|
& fig-input-text[type="number"],
|
|
2353
2361
|
& fig-input-number {
|
|
2354
2362
|
width: 3rem;
|
|
2355
2363
|
display: inline-flex;
|
|
2356
2364
|
}
|
|
2365
|
+
fig-input-text {
|
|
2366
|
+
width: auto;
|
|
2367
|
+
}
|
|
2357
2368
|
& > * {
|
|
2358
2369
|
flex: 1;
|
|
2359
2370
|
fig-input-text {
|
|
@@ -2785,8 +2796,323 @@ fig-shimmer:not([playing="false"]) > * {
|
|
|
2785
2796
|
animation: fig-shimmer var(--shimmer-duration) linear infinite;
|
|
2786
2797
|
}
|
|
2787
2798
|
|
|
2799
|
+
/* Fill Picker */
|
|
2800
|
+
fig-fill-picker {
|
|
2801
|
+
display: contents;
|
|
2802
|
+
}
|
|
2803
|
+
|
|
2804
|
+
.fig-fill-picker-dialog {
|
|
2805
|
+
width: 240px;
|
|
2806
|
+
padding: 0;
|
|
2807
|
+
|
|
2808
|
+
fig-header {
|
|
2809
|
+
padding: var(--spacer-2);
|
|
2810
|
+
display: flex;
|
|
2811
|
+
justify-content: space-between;
|
|
2812
|
+
align-items: center;
|
|
2813
|
+
}
|
|
2814
|
+
|
|
2815
|
+
fig-tab {
|
|
2816
|
+
font-size: 0.6875rem;
|
|
2817
|
+
padding: var(--spacer-1) var(--spacer-1);
|
|
2818
|
+
}
|
|
2819
|
+
}
|
|
2820
|
+
|
|
2821
|
+
.fig-fill-picker-type-label {
|
|
2822
|
+
font-size: var(--font-size-small);
|
|
2823
|
+
font-weight: var(--font-weight-medium);
|
|
2824
|
+
color: var(--figma-color-text);
|
|
2825
|
+
padding: var(--spacer-1) var(--spacer-2);
|
|
2826
|
+
}
|
|
2827
|
+
|
|
2828
|
+
.fig-fill-picker-content {
|
|
2829
|
+
padding: var(--spacer-3);
|
|
2830
|
+
}
|
|
2831
|
+
|
|
2832
|
+
.fig-fill-picker-tab {
|
|
2833
|
+
display: none;
|
|
2834
|
+
|
|
2835
|
+
&:first-child {
|
|
2836
|
+
display: block;
|
|
2837
|
+
}
|
|
2838
|
+
}
|
|
2839
|
+
|
|
2840
|
+
/* Solid Tab */
|
|
2841
|
+
.fig-fill-picker-color-area {
|
|
2842
|
+
position: relative;
|
|
2843
|
+
width: 100%;
|
|
2844
|
+
aspect-ratio: 1;
|
|
2845
|
+
border-radius: var(--radius-medium);
|
|
2846
|
+
overflow: visible;
|
|
2847
|
+
margin-bottom: var(--spacer-2);
|
|
2848
|
+
|
|
2849
|
+
canvas {
|
|
2850
|
+
width: 100%;
|
|
2851
|
+
height: 100%;
|
|
2852
|
+
border-radius: var(--radius-medium);
|
|
2853
|
+
}
|
|
2854
|
+
}
|
|
2855
|
+
|
|
2856
|
+
.fig-fill-picker-handle {
|
|
2857
|
+
position: absolute;
|
|
2858
|
+
width: 1rem;
|
|
2859
|
+
height: 1rem;
|
|
2860
|
+
border-radius: 50%;
|
|
2861
|
+
background: var(--picker-color);
|
|
2862
|
+
box-shadow: inset 0 0 0 0.125rem var(--handle-color),
|
|
2863
|
+
0px 0 0 0.5px rgba(0, 0, 0, 0.1), var(--figma-elevation-200);
|
|
2864
|
+
transform: translate(-50%, -50%);
|
|
2865
|
+
z-index: 1;
|
|
2866
|
+
&:hover {
|
|
2867
|
+
box-shadow: inset 0 0 0 0.25rem var(--handle-color),
|
|
2868
|
+
0px 0 0 0.5px rgba(0, 0, 0, 0.1), var(--figma-elevation-200);
|
|
2869
|
+
transform: translate(-50%, -50%);
|
|
2870
|
+
}
|
|
2871
|
+
}
|
|
2872
|
+
|
|
2873
|
+
.fig-fill-picker-sliders {
|
|
2874
|
+
display: flex;
|
|
2875
|
+
flex-direction: column;
|
|
2876
|
+
gap: var(--spacer-2);
|
|
2877
|
+
margin-bottom: var(--spacer-2);
|
|
2878
|
+
|
|
2879
|
+
fig-slider {
|
|
2880
|
+
width: 100%;
|
|
2881
|
+
}
|
|
2882
|
+
}
|
|
2883
|
+
|
|
2884
|
+
.fig-fill-picker-inputs {
|
|
2885
|
+
display: flex;
|
|
2886
|
+
gap: var(--spacer-1);
|
|
2887
|
+
align-items: center;
|
|
2888
|
+
|
|
2889
|
+
.fig-fill-picker-color-input {
|
|
2890
|
+
flex: 1;
|
|
2891
|
+
}
|
|
2892
|
+
}
|
|
2893
|
+
|
|
2894
|
+
/* Gradient Tab */
|
|
2895
|
+
.fig-fill-picker-gradient-header {
|
|
2896
|
+
display: flex;
|
|
2897
|
+
gap: var(--spacer-2);
|
|
2898
|
+
align-items: center;
|
|
2899
|
+
margin-bottom: var(--spacer-2);
|
|
2900
|
+
|
|
2901
|
+
& > *:last-child fig-button {
|
|
2902
|
+
margin-left: auto;
|
|
2903
|
+
}
|
|
2904
|
+
|
|
2905
|
+
.fig-fill-picker-gradient-center {
|
|
2906
|
+
fig-input-number {
|
|
2907
|
+
width: 48px;
|
|
2908
|
+
}
|
|
2909
|
+
}
|
|
2910
|
+
}
|
|
2911
|
+
|
|
2912
|
+
.fig-fill-picker-gradient-preview {
|
|
2913
|
+
position: relative;
|
|
2914
|
+
width: 100%;
|
|
2915
|
+
aspect-ratio: 1;
|
|
2916
|
+
border-radius: var(--radius-medium);
|
|
2917
|
+
overflow: hidden;
|
|
2918
|
+
margin-bottom: var(--spacer-2);
|
|
2919
|
+
}
|
|
2920
|
+
|
|
2921
|
+
.fig-fill-picker-gradient-bar {
|
|
2922
|
+
position: absolute;
|
|
2923
|
+
inset: 0;
|
|
2924
|
+
border-radius: var(--radius-medium);
|
|
2925
|
+
background: linear-gradient(90deg, #d9d9d9 0%, #737373 100%);
|
|
2926
|
+
}
|
|
2927
|
+
|
|
2928
|
+
.fig-fill-picker-gradient-stops-handles {
|
|
2929
|
+
position: absolute;
|
|
2930
|
+
top: 0;
|
|
2931
|
+
left: 0;
|
|
2932
|
+
right: 0;
|
|
2933
|
+
bottom: 0;
|
|
2934
|
+
pointer-events: none;
|
|
2935
|
+
}
|
|
2936
|
+
|
|
2937
|
+
.fig-fill-picker-gradient-stops {
|
|
2938
|
+
.fig-fill-picker-gradient-stops-header {
|
|
2939
|
+
display: flex;
|
|
2940
|
+
justify-content: space-between;
|
|
2941
|
+
align-items: center;
|
|
2942
|
+
margin-bottom: var(--spacer-1);
|
|
2943
|
+
font-size: 0.75rem;
|
|
2944
|
+
color: var(--figma-color-text-secondary);
|
|
2945
|
+
}
|
|
2946
|
+
}
|
|
2947
|
+
|
|
2948
|
+
.fig-fill-picker-gradient-stops-list {
|
|
2949
|
+
display: flex;
|
|
2950
|
+
flex-direction: column;
|
|
2951
|
+
gap: var(--spacer-1);
|
|
2952
|
+
}
|
|
2953
|
+
|
|
2954
|
+
.fig-fill-picker-gradient-stop-row {
|
|
2955
|
+
display: flex;
|
|
2956
|
+
gap: var(--spacer-1);
|
|
2957
|
+
align-items: center;
|
|
2958
|
+
|
|
2959
|
+
.fig-fill-picker-stop-position {
|
|
2960
|
+
width: 48px;
|
|
2961
|
+
flex-shrink: 0;
|
|
2962
|
+
}
|
|
2963
|
+
|
|
2964
|
+
.fig-fill-picker-stop-color {
|
|
2965
|
+
flex: 1;
|
|
2966
|
+
min-width: 0;
|
|
2967
|
+
fig-input-text {
|
|
2968
|
+
min-width: 0;
|
|
2969
|
+
}
|
|
2970
|
+
}
|
|
2971
|
+
|
|
2972
|
+
.fig-fill-picker-stop-remove {
|
|
2973
|
+
flex-shrink: 0;
|
|
2974
|
+
}
|
|
2975
|
+
}
|
|
2976
|
+
|
|
2977
|
+
/* Media Tabs (Image/Video/Webcam) */
|
|
2978
|
+
.fig-fill-picker-media-header {
|
|
2979
|
+
display: flex;
|
|
2980
|
+
gap: var(--spacer-1);
|
|
2981
|
+
align-items: center;
|
|
2982
|
+
margin-bottom: var(--spacer-2);
|
|
2983
|
+
|
|
2984
|
+
.fig-fill-picker-scale-mode {
|
|
2985
|
+
flex: 1;
|
|
2986
|
+
}
|
|
2987
|
+
|
|
2988
|
+
.fig-fill-picker-scale {
|
|
2989
|
+
width: 56px;
|
|
2990
|
+
}
|
|
2991
|
+
}
|
|
2992
|
+
|
|
2993
|
+
.fig-fill-picker-media-preview {
|
|
2994
|
+
position: relative;
|
|
2995
|
+
aspect-ratio: 1;
|
|
2996
|
+
border-radius: var(--radius-medium);
|
|
2997
|
+
overflow: hidden;
|
|
2998
|
+
display: flex;
|
|
2999
|
+
align-items: center;
|
|
3000
|
+
justify-content: center;
|
|
3001
|
+
|
|
3002
|
+
&.dragover {
|
|
3003
|
+
outline: 2px dashed var(--figma-color-border-brand);
|
|
3004
|
+
outline-offset: -2px;
|
|
3005
|
+
}
|
|
3006
|
+
|
|
3007
|
+
&.has-media {
|
|
3008
|
+
fig-button {
|
|
3009
|
+
visibility: hidden;
|
|
3010
|
+
}
|
|
3011
|
+
&:hover {
|
|
3012
|
+
fig-button {
|
|
3013
|
+
visibility: visible;
|
|
3014
|
+
}
|
|
3015
|
+
}
|
|
3016
|
+
}
|
|
3017
|
+
}
|
|
3018
|
+
|
|
3019
|
+
.fig-fill-picker-checkerboard {
|
|
3020
|
+
position: absolute;
|
|
3021
|
+
inset: 0;
|
|
3022
|
+
background-image: linear-gradient(
|
|
3023
|
+
45deg,
|
|
3024
|
+
var(--figma-color-bg-tertiary) 25%,
|
|
3025
|
+
transparent 25%
|
|
3026
|
+
),
|
|
3027
|
+
linear-gradient(-45deg, var(--figma-color-bg-tertiary) 25%, transparent 25%),
|
|
3028
|
+
linear-gradient(45deg, transparent 75%, var(--figma-color-bg-tertiary) 75%),
|
|
3029
|
+
linear-gradient(-45deg, transparent 75%, var(--figma-color-bg-tertiary) 75%);
|
|
3030
|
+
background-size: 16px 16px;
|
|
3031
|
+
background-position: 0 0, 0 8px, 8px -8px, -8px 0px;
|
|
3032
|
+
}
|
|
3033
|
+
|
|
3034
|
+
.fig-fill-picker-image-preview {
|
|
3035
|
+
position: absolute;
|
|
3036
|
+
inset: 0;
|
|
3037
|
+
width: 100%;
|
|
3038
|
+
height: 100%;
|
|
3039
|
+
display: none;
|
|
3040
|
+
}
|
|
3041
|
+
|
|
3042
|
+
.fig-fill-picker-video-preview {
|
|
3043
|
+
position: absolute;
|
|
3044
|
+
inset: 0;
|
|
3045
|
+
width: 100%;
|
|
3046
|
+
height: 100%;
|
|
3047
|
+
object-fit: cover;
|
|
3048
|
+
display: none;
|
|
3049
|
+
}
|
|
3050
|
+
|
|
3051
|
+
.fig-fill-picker-upload {
|
|
3052
|
+
position: relative;
|
|
3053
|
+
z-index: 1;
|
|
3054
|
+
}
|
|
3055
|
+
|
|
3056
|
+
/* Webcam Tab */
|
|
3057
|
+
.fig-fill-picker-webcam-preview {
|
|
3058
|
+
position: relative;
|
|
3059
|
+
aspect-ratio: 1;
|
|
3060
|
+
border-radius: var(--radius-medium);
|
|
3061
|
+
overflow: hidden;
|
|
3062
|
+
margin-bottom: var(--spacer-2);
|
|
3063
|
+
}
|
|
3064
|
+
|
|
3065
|
+
.fig-fill-picker-webcam-video {
|
|
3066
|
+
position: absolute;
|
|
3067
|
+
inset: 0;
|
|
3068
|
+
width: 100%;
|
|
3069
|
+
height: 100%;
|
|
3070
|
+
object-fit: cover;
|
|
3071
|
+
}
|
|
3072
|
+
|
|
3073
|
+
.fig-fill-picker-webcam-status {
|
|
3074
|
+
position: absolute;
|
|
3075
|
+
inset: 0;
|
|
3076
|
+
display: flex;
|
|
3077
|
+
align-items: center;
|
|
3078
|
+
justify-content: center;
|
|
3079
|
+
background: var(--figma-color-bg-secondary);
|
|
3080
|
+
color: var(--figma-color-text-secondary);
|
|
3081
|
+
font-size: 0.75rem;
|
|
3082
|
+
}
|
|
3083
|
+
|
|
3084
|
+
.fig-fill-picker-webcam-controls {
|
|
3085
|
+
display: flex;
|
|
3086
|
+
gap: var(--spacer-1);
|
|
3087
|
+
|
|
3088
|
+
.fig-fill-picker-camera-select {
|
|
3089
|
+
flex: 1;
|
|
3090
|
+
}
|
|
3091
|
+
|
|
3092
|
+
.fig-fill-picker-webcam-capture {
|
|
3093
|
+
flex-shrink: 0;
|
|
3094
|
+
}
|
|
3095
|
+
}
|
|
3096
|
+
|
|
2788
3097
|
/* Utilities */
|
|
2789
3098
|
|
|
3099
|
+
.fig-mask-icon {
|
|
3100
|
+
--size: var(--spacer-4);
|
|
3101
|
+
--icon: var(--icon-add);
|
|
3102
|
+
display: inline-flex;
|
|
3103
|
+
width: var(--size);
|
|
3104
|
+
height: var(--size);
|
|
3105
|
+
background: currentColor;
|
|
3106
|
+
mask-image: var(--icon);
|
|
3107
|
+
mask-size: contain;
|
|
3108
|
+
mask-repeat: no-repeat;
|
|
3109
|
+
mask-position: center;
|
|
3110
|
+
-webkit-mask-image: var(--icon);
|
|
3111
|
+
-webkit-mask-size: contain;
|
|
3112
|
+
-webkit-mask-repeat: no-repeat;
|
|
3113
|
+
-webkit-mask-position: center;
|
|
3114
|
+
}
|
|
3115
|
+
|
|
2790
3116
|
@keyframes fig-spinner-spin {
|
|
2791
3117
|
from {
|
|
2792
3118
|
transform: rotate(0deg);
|