ionbase-ui 0.25.0 → 0.27.0
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/components/Avatar.d.ts +33 -0
- package/dist/components/Avatar.d.ts.map +1 -1
- package/dist/components/Avatar.js +43 -4
- package/dist/components/Avatar.js.map +1 -1
- package/dist/components/AvatarGradient.d.ts +41 -0
- package/dist/components/AvatarGradient.d.ts.map +1 -0
- package/dist/components/AvatarGradient.js +32 -0
- package/dist/components/AvatarGradient.js.map +1 -0
- package/dist/components/index.d.ts +3 -1
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.js +1 -0
- package/dist/components/index.js.map +1 -1
- package/dist/figma-descriptions.json +34 -29
- package/dist/figma-map.json +115 -3
- package/dist/meta/Avatar.json +137 -7
- package/dist/meta/AvatarGradient.json +239 -0
- package/dist/meta/AvatarGroup.json +26 -3
- package/dist/meta/components.json +403 -11
- package/dist/meta/contrast.json +542 -162
- package/dist/meta/index.json +41 -1
- package/dist/meta/patterns/index.json +1 -1
- package/dist/styles/avatar-gradient.css +226 -0
- package/dist/styles/avatar.css +185 -19
- package/dist/styles/index.css +1 -0
- package/llms.txt +2 -2
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"package": "ionbase-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.27.0",
|
|
4
4
|
"generated": "by scripts/build-meta.mjs — do not edit; intent lives in meta/*.json",
|
|
5
5
|
"hooks": [
|
|
6
6
|
"useToast"
|
|
@@ -897,7 +897,7 @@
|
|
|
897
897
|
"name": "Avatar",
|
|
898
898
|
"source": "src/components/Avatar.tsx",
|
|
899
899
|
"propsType": "AvatarProps",
|
|
900
|
-
"description": "Avatar picks its content the way Figma's `Type` variant does, but by\nprecedence rather than by a prop: image, then initials, then icon. A caller\npassing `src` and `initials` gets the image with the initials as its alt\nfallback, which is what you want when the image 404s.\n\nA failed `src` falls through to initials (then icon) rather than leaving the\nbrowser's broken-image glyph — that is why initials exist alongside `src`.\n\nIt is a `<span>`, not a `<div>`, so it can sit inline beside text without the\ncaller fighting a block element.",
|
|
900
|
+
"description": "Avatar picks its content the way Figma's `Type` variant does, but by\nprecedence rather than by a prop: image, then initials, then icon. A caller\npassing `src` and `initials` gets the image with the initials as its alt\nfallback, which is what you want when the image 404s.\n\nA failed `src` falls through to initials (then icon) rather than leaving the\nbrowser's broken-image glyph — that is why initials exist alongside `src`.\n\nIt is a `<span>`, not a `<div>`, so it can sit inline beside text without the\ncaller fighting a block element.\n\nTHE MEDIA IS A CHILD, AND IT HAS TO BE\n\nThe box that clips the image is `.ion-avatar__media`, not the root. The root\ncannot clip: a corner indicator sits outside a circle's clip path and would\nbe sliced in half by the `overflow: hidden` that crops the photo. Figma\ndraws exactly this — an unclipped frame holding a clipped `Media` child and\nthe indicators as its siblings.",
|
|
901
901
|
"import": "import { Avatar } from 'ionbase-ui';",
|
|
902
902
|
"status": "stable",
|
|
903
903
|
"summary": "A person or entity marker. Content is chosen by precedence — image, then initials, then icon — not by a type prop.",
|
|
@@ -937,21 +937,67 @@
|
|
|
937
937
|
"square": {
|
|
938
938
|
"use": "organisations, projects, workspaces and other non-human entities"
|
|
939
939
|
}
|
|
940
|
+
},
|
|
941
|
+
"topIndicator": {
|
|
942
|
+
"neutral": {
|
|
943
|
+
"use": "no state, or a state this system has no colour for"
|
|
944
|
+
},
|
|
945
|
+
"primary": {
|
|
946
|
+
"use": "attention rather than health — a request, an invite, a mention"
|
|
947
|
+
},
|
|
948
|
+
"success": {
|
|
949
|
+
"use": "online, available, verified, complete"
|
|
950
|
+
},
|
|
951
|
+
"warning": {
|
|
952
|
+
"use": "away, idle, needs attention but is not broken"
|
|
953
|
+
},
|
|
954
|
+
"error": {
|
|
955
|
+
"use": "offline, blocked, failed"
|
|
956
|
+
},
|
|
957
|
+
"information": {
|
|
958
|
+
"use": "a neutral fact about the person — a role or a badge, not a state"
|
|
959
|
+
}
|
|
960
|
+
},
|
|
961
|
+
"bottomIndicator": {
|
|
962
|
+
"neutral": {
|
|
963
|
+
"use": "no state, or a state this system has no colour for"
|
|
964
|
+
},
|
|
965
|
+
"primary": {
|
|
966
|
+
"use": "attention rather than health — a request, an invite, a mention"
|
|
967
|
+
},
|
|
968
|
+
"success": {
|
|
969
|
+
"use": "online, available, verified, complete"
|
|
970
|
+
},
|
|
971
|
+
"warning": {
|
|
972
|
+
"use": "away, idle, needs attention but is not broken"
|
|
973
|
+
},
|
|
974
|
+
"error": {
|
|
975
|
+
"use": "offline, blocked, failed"
|
|
976
|
+
},
|
|
977
|
+
"information": {
|
|
978
|
+
"use": "a neutral fact about the person — a role or a badge, not a state"
|
|
979
|
+
}
|
|
940
980
|
}
|
|
941
981
|
},
|
|
942
982
|
"slots": {
|
|
943
983
|
"icon": {
|
|
944
984
|
"accepts": "Icon",
|
|
945
985
|
"note": "the last fallback — rendered only when there is neither `src` nor `initials`"
|
|
986
|
+
},
|
|
987
|
+
"topIndicatorIcon": {
|
|
988
|
+
"accepts": "Icon",
|
|
989
|
+
"note": "replaces the top indicator's default check glyph. The bottom indicator takes no glyph — Figma draws it bare, and at Mini it is 8px, which nothing legible fits inside."
|
|
946
990
|
}
|
|
947
991
|
},
|
|
948
992
|
"a11y": {
|
|
949
993
|
"guarantees": [
|
|
950
994
|
"`alt` falls back to `initials`, so the avatar is never announced as an unlabelled image",
|
|
951
|
-
"a `src` that fails to load falls through to initials, then icon — never the browser's broken-image glyph"
|
|
995
|
+
"a `src` that fails to load falls through to initials, then icon — never the browser's broken-image glyph",
|
|
996
|
+
"indicator labels are announced wherever they land: folded into the avatar's own `aria-label` when there is no image (the root is `role=\"img\"` and therefore a leaf), and carried as hidden text inside each indicator when there is"
|
|
952
997
|
],
|
|
953
998
|
"requires": [
|
|
954
|
-
"`alt` describing the person, not the picture — \"Ada Lovelace\", not \"profile photo\""
|
|
999
|
+
"`alt` describing the person, not the picture — \"Ada Lovelace\", not \"profile photo\"",
|
|
1000
|
+
"`topIndicatorLabel` / `bottomIndicatorLabel` on any indicator that carries meaning. An indicator with no label is decorative, which is the right answer only when the same fact is already stated in text beside it."
|
|
955
1001
|
]
|
|
956
1002
|
},
|
|
957
1003
|
"antiPatterns": [
|
|
@@ -963,43 +1009,75 @@
|
|
|
963
1009
|
"dont": "using Avatar as a button",
|
|
964
1010
|
"do": "put the Avatar inside a Button or Link",
|
|
965
1011
|
"why": "Avatar renders a <span> with no role and takes no focus"
|
|
1012
|
+
},
|
|
1013
|
+
{
|
|
1014
|
+
"dont": "using an indicator's colour as the only carrier of a status",
|
|
1015
|
+
"do": "pass `topIndicatorLabel` / `bottomIndicatorLabel`, or state the status in text nearby",
|
|
1016
|
+
"why": "WCAG 1.4.1. A green dot and a red dot are the same dot to a screen reader, and to a good share of sighted users too"
|
|
1017
|
+
},
|
|
1018
|
+
{
|
|
1019
|
+
"dont": "reaching for `ring` to mean selected or focused",
|
|
1020
|
+
"why": "it is a static brand ring from the design, not a focus indicator. Focus belongs on whatever interactive element wraps the avatar, and that element draws its own"
|
|
966
1021
|
}
|
|
967
1022
|
],
|
|
968
1023
|
"stylesheet": "src/styles/avatar.css",
|
|
969
1024
|
"tokens": [
|
|
970
1025
|
"--border-strong",
|
|
1026
|
+
"--border-subtle",
|
|
971
1027
|
"--border-width-default",
|
|
1028
|
+
"--border-width-thick",
|
|
972
1029
|
"--font-family-sans",
|
|
973
1030
|
"--font-weight-medium",
|
|
1031
|
+
"--font-weight-regular",
|
|
974
1032
|
"--icon-size-2xs",
|
|
975
1033
|
"--icon-size-lg",
|
|
976
1034
|
"--icon-size-md",
|
|
977
1035
|
"--icon-size-sm",
|
|
978
1036
|
"--icon-tertiary",
|
|
1037
|
+
"--ion-avatar-border",
|
|
979
1038
|
"--ion-avatar-font-size",
|
|
1039
|
+
"--ion-avatar-font-weight",
|
|
980
1040
|
"--ion-avatar-group-overlap",
|
|
981
1041
|
"--ion-avatar-icon",
|
|
1042
|
+
"--ion-avatar-indicator-icon",
|
|
1043
|
+
"--ion-avatar-indicator-ring",
|
|
1044
|
+
"--ion-avatar-indicator-size",
|
|
982
1045
|
"--ion-avatar-line-height",
|
|
983
1046
|
"--ion-avatar-radius",
|
|
1047
|
+
"--ion-avatar-ring-width",
|
|
984
1048
|
"--ion-avatar-size",
|
|
1049
|
+
"--ion-avatar-surface",
|
|
985
1050
|
"--radius-full",
|
|
986
1051
|
"--radius-md",
|
|
987
1052
|
"--radius-sm",
|
|
988
1053
|
"--radius-xs",
|
|
1054
|
+
"--ring-offset",
|
|
1055
|
+
"--spacing-12",
|
|
1056
|
+
"--spacing-14",
|
|
1057
|
+
"--spacing-16",
|
|
989
1058
|
"--spacing-24",
|
|
990
1059
|
"--spacing-32",
|
|
991
1060
|
"--spacing-40",
|
|
992
1061
|
"--spacing-48",
|
|
1062
|
+
"--spacing-8",
|
|
1063
|
+
"--surface-error",
|
|
1064
|
+
"--surface-information",
|
|
1065
|
+
"--surface-inverse",
|
|
993
1066
|
"--surface-muted",
|
|
1067
|
+
"--surface-placeholder",
|
|
1068
|
+
"--surface-primary",
|
|
1069
|
+
"--surface-success",
|
|
1070
|
+
"--surface-warning",
|
|
1071
|
+
"--text-on-color",
|
|
994
1072
|
"--text-tertiary",
|
|
995
1073
|
"--type-body",
|
|
1074
|
+
"--type-body-lg",
|
|
1075
|
+
"--type-body-lg-line-height",
|
|
996
1076
|
"--type-body-line-height",
|
|
997
1077
|
"--type-body-sm",
|
|
998
1078
|
"--type-body-sm-line-height",
|
|
999
1079
|
"--type-caption",
|
|
1000
|
-
"--type-caption-line-height"
|
|
1001
|
-
"--type-h5",
|
|
1002
|
-
"--type-h5-line-height"
|
|
1080
|
+
"--type-caption-line-height"
|
|
1003
1081
|
],
|
|
1004
1082
|
"props": {
|
|
1005
1083
|
"size": {
|
|
@@ -1047,15 +1125,306 @@
|
|
|
1047
1125
|
"required": false,
|
|
1048
1126
|
"origin": "own",
|
|
1049
1127
|
"description": "Figma's `Type=Icon`. Rendered when there is neither `src` nor `initials`."
|
|
1128
|
+
},
|
|
1129
|
+
"ring": {
|
|
1130
|
+
"type": "boolean | undefined",
|
|
1131
|
+
"required": false,
|
|
1132
|
+
"origin": "own",
|
|
1133
|
+
"description": "Figma's `Show Ring` — a 1px/2px brand ring drawn inside the avatar's edge."
|
|
1134
|
+
},
|
|
1135
|
+
"topIndicator": {
|
|
1136
|
+
"type": "AvatarIndicatorIntent | undefined",
|
|
1137
|
+
"required": false,
|
|
1138
|
+
"origin": "own",
|
|
1139
|
+
"description": "Figma's `Show Top Indicator`, as the intent of the `Status Indicator`\ninstance it holds. Top-right, and it carries a glyph: this is the corner\nthat says something was verified or requested, not who is online.",
|
|
1140
|
+
"values": [
|
|
1141
|
+
"neutral",
|
|
1142
|
+
"primary",
|
|
1143
|
+
"success",
|
|
1144
|
+
"warning",
|
|
1145
|
+
"error",
|
|
1146
|
+
"information"
|
|
1147
|
+
]
|
|
1148
|
+
},
|
|
1149
|
+
"topIndicatorIcon": {
|
|
1150
|
+
"type": "React.ReactNode",
|
|
1151
|
+
"required": false,
|
|
1152
|
+
"origin": "own",
|
|
1153
|
+
"description": "Replaces the top indicator's default check glyph."
|
|
1154
|
+
},
|
|
1155
|
+
"topIndicatorLabel": {
|
|
1156
|
+
"type": "string | undefined",
|
|
1157
|
+
"required": false,
|
|
1158
|
+
"origin": "own",
|
|
1159
|
+
"description": "Names the top indicator for assistive tech. Without it the mark is decorative."
|
|
1160
|
+
},
|
|
1161
|
+
"bottomIndicator": {
|
|
1162
|
+
"type": "AvatarIndicatorIntent | undefined",
|
|
1163
|
+
"required": false,
|
|
1164
|
+
"origin": "own",
|
|
1165
|
+
"description": "Figma's `Show Bottom Indicator`. Bottom-right and glyphless — the presence\ndot.",
|
|
1166
|
+
"values": [
|
|
1167
|
+
"neutral",
|
|
1168
|
+
"primary",
|
|
1169
|
+
"success",
|
|
1170
|
+
"warning",
|
|
1171
|
+
"error",
|
|
1172
|
+
"information"
|
|
1173
|
+
]
|
|
1174
|
+
},
|
|
1175
|
+
"bottomIndicatorLabel": {
|
|
1176
|
+
"type": "string | undefined",
|
|
1177
|
+
"required": false,
|
|
1178
|
+
"origin": "own",
|
|
1179
|
+
"description": "Names the bottom indicator for assistive tech. Colour alone is not a status."
|
|
1050
1180
|
}
|
|
1051
1181
|
},
|
|
1052
1182
|
"propCounts": {
|
|
1053
|
-
"own":
|
|
1183
|
+
"own": 12,
|
|
1054
1184
|
"aria": 0,
|
|
1055
1185
|
"dom": 278,
|
|
1056
1186
|
"other": 0
|
|
1057
1187
|
}
|
|
1058
1188
|
},
|
|
1189
|
+
"AvatarGradient": {
|
|
1190
|
+
"name": "AvatarGradient",
|
|
1191
|
+
"source": "src/components/AvatarGradient.tsx",
|
|
1192
|
+
"propsType": "AvatarGradientProps",
|
|
1193
|
+
"description": "AvatarGradient is Avatar's initials-only sibling: a lit, bevelled disc for\npeople who have no photo.\n\nIT IS A SEPARATE COMPONENT BECAUSE FIGMA DRAWS A SEPARATE COMPONENT, AND THE\nAXES ARE THE ARGUMENT\n\nIt has `Color`, which Avatar does not. It has no `Shape`, because a gradient\nthis directional only reads on a circle. It has no `Type`, because there is\nno image and no icon to fall back to — the initials are the whole content.\nFolding it into Avatar would mean a `color` prop that does nothing on three\nof Avatar's four states and a `shape` prop that this one has to reject.\n\nThere is no `icon` and no `src` fallback here on purpose. If you have a\nphoto, or nothing at all to put in the circle, that is `Avatar`.",
|
|
1194
|
+
"import": "import { AvatarGradient } from 'ionbase-ui';",
|
|
1195
|
+
"status": "stable",
|
|
1196
|
+
"summary": "Avatar's initials-only sibling: a lit, bevelled disc in one of eight colours, for people with no photo.",
|
|
1197
|
+
"useWhen": [
|
|
1198
|
+
"someone has no profile image and the fallback should still look deliberate rather than empty",
|
|
1199
|
+
"a list of people reads better when each one is a different colour — the colour is recognisable long before the letters are legible"
|
|
1200
|
+
],
|
|
1201
|
+
"useInstead": [
|
|
1202
|
+
{
|
|
1203
|
+
"when": "there is a photo, or there may be one later",
|
|
1204
|
+
"use": "Avatar",
|
|
1205
|
+
"why": "Avatar falls back from image to initials to icon on its own; this component has no image to fall back from"
|
|
1206
|
+
},
|
|
1207
|
+
{
|
|
1208
|
+
"when": "the mark needs a square shape, an icon, a ring or a status indicator",
|
|
1209
|
+
"use": "Avatar",
|
|
1210
|
+
"why": "Figma draws none of those on this component, and a gradient this directional only reads on a circle"
|
|
1211
|
+
},
|
|
1212
|
+
{
|
|
1213
|
+
"when": "the thing being marked is a status, count or category rather than a person",
|
|
1214
|
+
"use": "Badge"
|
|
1215
|
+
}
|
|
1216
|
+
],
|
|
1217
|
+
"variants": {
|
|
1218
|
+
"size": {
|
|
1219
|
+
"mini": {
|
|
1220
|
+
"use": "24px — inline beside body text, dense table rows"
|
|
1221
|
+
},
|
|
1222
|
+
"sm": {
|
|
1223
|
+
"use": "32px — menu rows, compact lists"
|
|
1224
|
+
},
|
|
1225
|
+
"md": {
|
|
1226
|
+
"use": "the default, 40px"
|
|
1227
|
+
},
|
|
1228
|
+
"lg": {
|
|
1229
|
+
"use": "48px — profile headers and detail pages"
|
|
1230
|
+
}
|
|
1231
|
+
},
|
|
1232
|
+
"color": {
|
|
1233
|
+
"slate": {
|
|
1234
|
+
"use": "the default. The one to reach for when nothing about the person suggests a colour"
|
|
1235
|
+
},
|
|
1236
|
+
"blue": {
|
|
1237
|
+
"use": "as slate — one of seven, picked to tell people apart"
|
|
1238
|
+
},
|
|
1239
|
+
"violet": {
|
|
1240
|
+
"use": "as slate"
|
|
1241
|
+
},
|
|
1242
|
+
"pink": {
|
|
1243
|
+
"use": "as slate. See `a11y.knownIssues` before putting it behind text that matters"
|
|
1244
|
+
},
|
|
1245
|
+
"orange": {
|
|
1246
|
+
"use": "as slate. See `a11y.knownIssues`"
|
|
1247
|
+
},
|
|
1248
|
+
"green": {
|
|
1249
|
+
"use": "as slate. Not a status — a green disc here does not mean online, and Avatar's `bottomIndicator` is what does"
|
|
1250
|
+
},
|
|
1251
|
+
"red": {
|
|
1252
|
+
"use": "as slate. Not an error — this is identity, not state. See `a11y.knownIssues`"
|
|
1253
|
+
},
|
|
1254
|
+
"light": {
|
|
1255
|
+
"use": "dark text on a near-white disc, for dense surfaces where seven saturated circles would shout"
|
|
1256
|
+
}
|
|
1257
|
+
}
|
|
1258
|
+
},
|
|
1259
|
+
"a11y": {
|
|
1260
|
+
"guarantees": [
|
|
1261
|
+
"`alt` falls back to `initials`, so the disc is never announced as an unlabelled image"
|
|
1262
|
+
],
|
|
1263
|
+
"requires": [
|
|
1264
|
+
"`alt` naming the person — \"Ada Lovelace\", not \"AB\". Two letters are not a name, and that is all a screen reader would otherwise get"
|
|
1265
|
+
],
|
|
1266
|
+
"notes": [
|
|
1267
|
+
"Colour is decoration here, never information. Nothing about which of the eight a person gets should be recoverable, because a screen reader cannot recover it."
|
|
1268
|
+
],
|
|
1269
|
+
"knownIssues": [
|
|
1270
|
+
{
|
|
1271
|
+
"pairing": "--color-base-white on --color-pink-500",
|
|
1272
|
+
"mode": "Light",
|
|
1273
|
+
"ratio": 3.53,
|
|
1274
|
+
"required": 4.5,
|
|
1275
|
+
"sc": "1.4.3",
|
|
1276
|
+
"states": [
|
|
1277
|
+
"default"
|
|
1278
|
+
],
|
|
1279
|
+
"status": "known, not yet fixed"
|
|
1280
|
+
},
|
|
1281
|
+
{
|
|
1282
|
+
"pairing": "--color-base-white on --color-orange-500",
|
|
1283
|
+
"mode": "Light",
|
|
1284
|
+
"ratio": 3.6,
|
|
1285
|
+
"required": 4.5,
|
|
1286
|
+
"sc": "1.4.3",
|
|
1287
|
+
"states": [
|
|
1288
|
+
"default"
|
|
1289
|
+
],
|
|
1290
|
+
"status": "known, not yet fixed"
|
|
1291
|
+
},
|
|
1292
|
+
{
|
|
1293
|
+
"pairing": "--color-base-white on --color-green-500",
|
|
1294
|
+
"mode": "Light",
|
|
1295
|
+
"ratio": 3.69,
|
|
1296
|
+
"required": 4.5,
|
|
1297
|
+
"sc": "1.4.3",
|
|
1298
|
+
"states": [
|
|
1299
|
+
"default"
|
|
1300
|
+
],
|
|
1301
|
+
"status": "known, not yet fixed"
|
|
1302
|
+
},
|
|
1303
|
+
{
|
|
1304
|
+
"pairing": "--color-base-white on --color-red-500",
|
|
1305
|
+
"mode": "Light",
|
|
1306
|
+
"ratio": 3.78,
|
|
1307
|
+
"required": 4.5,
|
|
1308
|
+
"sc": "1.4.3",
|
|
1309
|
+
"states": [
|
|
1310
|
+
"default"
|
|
1311
|
+
],
|
|
1312
|
+
"status": "known, not yet fixed"
|
|
1313
|
+
}
|
|
1314
|
+
]
|
|
1315
|
+
},
|
|
1316
|
+
"antiPatterns": [
|
|
1317
|
+
{
|
|
1318
|
+
"dont": "picking the colour from a status — green for online, red for failing",
|
|
1319
|
+
"do": "use Avatar's `bottomIndicator`, or say it in text",
|
|
1320
|
+
"why": "the colour is identity, not state. It is also invisible to assistive tech, so a status expressed only this way is not expressed at all"
|
|
1321
|
+
},
|
|
1322
|
+
{
|
|
1323
|
+
"dont": "hashing a user id to a colour and treating it as stable",
|
|
1324
|
+
"do": "store the chosen colour with the person, the way you would store their avatar",
|
|
1325
|
+
"why": "the palette has eight entries and any hash of it will collide; worse, it silently reassigns everyone the day the palette or the hash changes"
|
|
1326
|
+
},
|
|
1327
|
+
{
|
|
1328
|
+
"dont": "passing more than two letters",
|
|
1329
|
+
"why": "Figma draws two. Three fit at 48 and clip at 24, so it looks correct in the story and wrong in the table"
|
|
1330
|
+
}
|
|
1331
|
+
],
|
|
1332
|
+
"stylesheet": "src/styles/avatar-gradient.css",
|
|
1333
|
+
"tokens": [
|
|
1334
|
+
"--color-base-white",
|
|
1335
|
+
"--color-blue-500",
|
|
1336
|
+
"--color-blue-600",
|
|
1337
|
+
"--color-gray-100",
|
|
1338
|
+
"--color-gray-200",
|
|
1339
|
+
"--color-gray-500",
|
|
1340
|
+
"--color-gray-600",
|
|
1341
|
+
"--color-gray-900",
|
|
1342
|
+
"--color-green-500",
|
|
1343
|
+
"--color-green-600",
|
|
1344
|
+
"--color-orange-500",
|
|
1345
|
+
"--color-orange-600",
|
|
1346
|
+
"--color-pink-500",
|
|
1347
|
+
"--color-pink-600",
|
|
1348
|
+
"--color-purple-500",
|
|
1349
|
+
"--color-purple-600",
|
|
1350
|
+
"--color-red-500",
|
|
1351
|
+
"--color-red-600",
|
|
1352
|
+
"--font-family-sans",
|
|
1353
|
+
"--font-weight-medium",
|
|
1354
|
+
"--font-weight-regular",
|
|
1355
|
+
"--ion-avatar-gradient-elevation",
|
|
1356
|
+
"--ion-avatar-gradient-font-size",
|
|
1357
|
+
"--ion-avatar-gradient-font-weight",
|
|
1358
|
+
"--ion-avatar-gradient-from",
|
|
1359
|
+
"--ion-avatar-gradient-line-height",
|
|
1360
|
+
"--ion-avatar-gradient-sheen",
|
|
1361
|
+
"--ion-avatar-gradient-sheen-mid",
|
|
1362
|
+
"--ion-avatar-gradient-size",
|
|
1363
|
+
"--ion-avatar-gradient-text",
|
|
1364
|
+
"--ion-avatar-gradient-to",
|
|
1365
|
+
"--radius-full",
|
|
1366
|
+
"--spacing-24",
|
|
1367
|
+
"--spacing-32",
|
|
1368
|
+
"--spacing-40",
|
|
1369
|
+
"--spacing-48",
|
|
1370
|
+
"--type-body",
|
|
1371
|
+
"--type-body-lg",
|
|
1372
|
+
"--type-body-lg-line-height",
|
|
1373
|
+
"--type-body-line-height",
|
|
1374
|
+
"--type-body-sm",
|
|
1375
|
+
"--type-body-sm-line-height",
|
|
1376
|
+
"--type-caption",
|
|
1377
|
+
"--type-caption-line-height"
|
|
1378
|
+
],
|
|
1379
|
+
"props": {
|
|
1380
|
+
"size": {
|
|
1381
|
+
"type": "AvatarSize | undefined",
|
|
1382
|
+
"required": false,
|
|
1383
|
+
"origin": "own",
|
|
1384
|
+
"description": "Matches the Figma `Size` variant: Mini 24, Small 32, Medium 40, Large 48.",
|
|
1385
|
+
"values": [
|
|
1386
|
+
"sm",
|
|
1387
|
+
"md",
|
|
1388
|
+
"lg",
|
|
1389
|
+
"mini"
|
|
1390
|
+
]
|
|
1391
|
+
},
|
|
1392
|
+
"color": {
|
|
1393
|
+
"type": "AvatarGradientColor | undefined",
|
|
1394
|
+
"required": false,
|
|
1395
|
+
"origin": "own",
|
|
1396
|
+
"description": "Matches the Figma `Color` variant.",
|
|
1397
|
+
"values": [
|
|
1398
|
+
"slate",
|
|
1399
|
+
"blue",
|
|
1400
|
+
"violet",
|
|
1401
|
+
"pink",
|
|
1402
|
+
"orange",
|
|
1403
|
+
"green",
|
|
1404
|
+
"red",
|
|
1405
|
+
"light"
|
|
1406
|
+
]
|
|
1407
|
+
},
|
|
1408
|
+
"initials": {
|
|
1409
|
+
"type": "string | undefined",
|
|
1410
|
+
"required": false,
|
|
1411
|
+
"origin": "own",
|
|
1412
|
+
"description": "The two letters. Figma's `Initials`."
|
|
1413
|
+
},
|
|
1414
|
+
"alt": {
|
|
1415
|
+
"type": "string | undefined",
|
|
1416
|
+
"required": false,
|
|
1417
|
+
"origin": "own",
|
|
1418
|
+
"description": "Describes the person, not the picture — \"Ada Lovelace\", not \"avatar\".\nWithout it the initials are announced as the letters they are, which is\nnot a name."
|
|
1419
|
+
}
|
|
1420
|
+
},
|
|
1421
|
+
"propCounts": {
|
|
1422
|
+
"own": 4,
|
|
1423
|
+
"aria": 0,
|
|
1424
|
+
"dom": 277,
|
|
1425
|
+
"other": 0
|
|
1426
|
+
}
|
|
1427
|
+
},
|
|
1059
1428
|
"AvatarGroup": {
|
|
1060
1429
|
"name": "AvatarGroup",
|
|
1061
1430
|
"source": "src/components/Avatar.tsx",
|
|
@@ -1122,38 +1491,61 @@
|
|
|
1122
1491
|
"stylesheet": "src/styles/avatar.css",
|
|
1123
1492
|
"tokens": [
|
|
1124
1493
|
"--border-strong",
|
|
1494
|
+
"--border-subtle",
|
|
1125
1495
|
"--border-width-default",
|
|
1496
|
+
"--border-width-thick",
|
|
1126
1497
|
"--font-family-sans",
|
|
1127
1498
|
"--font-weight-medium",
|
|
1499
|
+
"--font-weight-regular",
|
|
1128
1500
|
"--icon-size-2xs",
|
|
1129
1501
|
"--icon-size-lg",
|
|
1130
1502
|
"--icon-size-md",
|
|
1131
1503
|
"--icon-size-sm",
|
|
1132
1504
|
"--icon-tertiary",
|
|
1505
|
+
"--ion-avatar-border",
|
|
1133
1506
|
"--ion-avatar-font-size",
|
|
1507
|
+
"--ion-avatar-font-weight",
|
|
1134
1508
|
"--ion-avatar-group-overlap",
|
|
1135
1509
|
"--ion-avatar-icon",
|
|
1510
|
+
"--ion-avatar-indicator-icon",
|
|
1511
|
+
"--ion-avatar-indicator-ring",
|
|
1512
|
+
"--ion-avatar-indicator-size",
|
|
1136
1513
|
"--ion-avatar-line-height",
|
|
1137
1514
|
"--ion-avatar-radius",
|
|
1515
|
+
"--ion-avatar-ring-width",
|
|
1138
1516
|
"--ion-avatar-size",
|
|
1517
|
+
"--ion-avatar-surface",
|
|
1139
1518
|
"--radius-full",
|
|
1140
1519
|
"--radius-md",
|
|
1141
1520
|
"--radius-sm",
|
|
1142
1521
|
"--radius-xs",
|
|
1522
|
+
"--ring-offset",
|
|
1523
|
+
"--spacing-12",
|
|
1524
|
+
"--spacing-14",
|
|
1525
|
+
"--spacing-16",
|
|
1143
1526
|
"--spacing-24",
|
|
1144
1527
|
"--spacing-32",
|
|
1145
1528
|
"--spacing-40",
|
|
1146
1529
|
"--spacing-48",
|
|
1530
|
+
"--spacing-8",
|
|
1531
|
+
"--surface-error",
|
|
1532
|
+
"--surface-information",
|
|
1533
|
+
"--surface-inverse",
|
|
1147
1534
|
"--surface-muted",
|
|
1535
|
+
"--surface-placeholder",
|
|
1536
|
+
"--surface-primary",
|
|
1537
|
+
"--surface-success",
|
|
1538
|
+
"--surface-warning",
|
|
1539
|
+
"--text-on-color",
|
|
1148
1540
|
"--text-tertiary",
|
|
1149
1541
|
"--type-body",
|
|
1542
|
+
"--type-body-lg",
|
|
1543
|
+
"--type-body-lg-line-height",
|
|
1150
1544
|
"--type-body-line-height",
|
|
1151
1545
|
"--type-body-sm",
|
|
1152
1546
|
"--type-body-sm-line-height",
|
|
1153
1547
|
"--type-caption",
|
|
1154
|
-
"--type-caption-line-height"
|
|
1155
|
-
"--type-h5",
|
|
1156
|
-
"--type-h5-line-height"
|
|
1548
|
+
"--type-caption-line-height"
|
|
1157
1549
|
],
|
|
1158
1550
|
"props": {
|
|
1159
1551
|
"size": {
|