@jobber/components-native 0.101.5 → 0.101.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.
Files changed (67) hide show
  1. package/dist/docs/ActionItem/ActionItem.md +65 -0
  2. package/dist/docs/ActionItemGroup/ActionItemGroup.md +33 -0
  3. package/dist/docs/ActionLabel/ActionLabel.md +43 -0
  4. package/dist/docs/ActivityIndicator/ActivityIndicator.md +116 -0
  5. package/dist/docs/Animation/Animation.md +71 -0
  6. package/dist/docs/AtlantisThemeContext/AtlantisThemeContext.md +256 -0
  7. package/dist/docs/AutoLink/AutoLink.md +47 -0
  8. package/dist/docs/Banner/Banner.md +390 -0
  9. package/dist/docs/Borders/Borders.md +45 -0
  10. package/dist/docs/BottomSheet/BottomSheet.md +67 -0
  11. package/dist/docs/Button/Button.md +918 -0
  12. package/dist/docs/ButtonGroup/ButtonGroup.md +89 -0
  13. package/dist/docs/Card/Card.md +270 -0
  14. package/dist/docs/Checkbox/Checkbox.md +69 -0
  15. package/dist/docs/Chip/Chip.md +371 -0
  16. package/dist/docs/Colors/Colors.md +217 -0
  17. package/dist/docs/Content/Content.md +67 -0
  18. package/dist/docs/ContentOverlay/ContentOverlay.md +64 -0
  19. package/dist/docs/Disclosure/Disclosure.md +161 -0
  20. package/dist/docs/Divider/Divider.md +84 -0
  21. package/dist/docs/Elevations/Elevations.md +76 -0
  22. package/dist/docs/EmptyState/EmptyState.md +72 -0
  23. package/dist/docs/Flex/Flex.md +37 -0
  24. package/dist/docs/Form/Form.md +126 -0
  25. package/dist/docs/FormField/FormField.md +57 -0
  26. package/dist/docs/FormatFile/FormatFile.md +56 -0
  27. package/dist/docs/Glimmer/Glimmer.md +143 -0
  28. package/dist/docs/Heading/Heading.md +132 -0
  29. package/dist/docs/Icon/Icon.md +585 -0
  30. package/dist/docs/IconButton/IconButton.md +25 -0
  31. package/dist/docs/InputCurrency/InputCurrency.md +61 -0
  32. package/dist/docs/InputDate/InputDate.md +133 -0
  33. package/dist/docs/InputEmail/InputEmail.md +69 -0
  34. package/dist/docs/InputFieldWrapper/InputFieldWrapper.md +70 -0
  35. package/dist/docs/InputNumber/InputNumber.md +72 -0
  36. package/dist/docs/InputPassword/InputPassword.md +61 -0
  37. package/dist/docs/InputPressable/InputPressable.md +64 -0
  38. package/dist/docs/InputSearch/InputSearch.md +49 -0
  39. package/dist/docs/InputText/InputText.md +324 -0
  40. package/dist/docs/InputTime/InputTime.md +54 -0
  41. package/dist/docs/Opacity/Opacity.md +12 -0
  42. package/dist/docs/ProgressBar/ProgressBar.md +39 -0
  43. package/dist/docs/Radii/Radii.md +23 -0
  44. package/dist/docs/ResponsiveBreakpoint/ResponsiveBreakpoint.md +74 -0
  45. package/dist/docs/Select/Select.md +213 -0
  46. package/dist/docs/Spacing/Spacing.md +103 -0
  47. package/dist/docs/StatusLabel/StatusLabel.md +119 -0
  48. package/dist/docs/Switch/Switch.md +54 -0
  49. package/dist/docs/Text/Text.md +368 -0
  50. package/dist/docs/TextList/TextList.md +29 -0
  51. package/dist/docs/ThumbnailList/ThumbnailList.md +16 -0
  52. package/dist/docs/Toast/Toast.md +71 -0
  53. package/dist/docs/Typography/Typography.md +170 -0
  54. package/dist/docs/choosing-components/choosing-components.md +76 -0
  55. package/dist/docs/customizing-components/customizing-components.md +167 -0
  56. package/dist/docs/disabled-states/disabled-states.md +86 -0
  57. package/dist/docs/empty-states/empty-states.md +126 -0
  58. package/dist/docs/errors/errors.md +114 -0
  59. package/dist/docs/index.md +64 -0
  60. package/dist/docs/interaction/interaction.md +109 -0
  61. package/dist/docs/page-layouts/page-layouts.md +323 -0
  62. package/dist/docs/scaffolding/scaffolding.md +109 -0
  63. package/dist/docs/settings/settings.md +58 -0
  64. package/dist/docs/usage-guidelines/usage-guidelines.md +177 -0
  65. package/dist/package.json +8 -4
  66. package/dist/tsconfig.build.tsbuildinfo +1 -1
  67. package/package.json +8 -4
@@ -0,0 +1,368 @@
1
+ # Text
2
+
3
+ Text is used to add an additional visual meaning on your content
4
+
5
+ ## Design & usage guidelines
6
+
7
+ The default styling of a text is used as the body text for almost everything.
8
+
9
+ ```tsx
10
+ import React from "react";
11
+ import { Text } from "@jobber/components/Text";
12
+
13
+ export function TextDefaultExample() {
14
+ return (
15
+ <Text>Ask the information you need upfront from clients and new leads</Text>
16
+ );
17
+ }
18
+ ```
19
+
20
+ ### Subdued
21
+
22
+ De-emphasize a piece of text that is less important to the user.
23
+
24
+ ```tsx
25
+ import React from "react";
26
+ import { Text } from "@jobber/components/Text";
27
+
28
+ export function TextSubduedExample() {
29
+ return <Text variation="subdued">Job note linked to related invoice</Text>;
30
+ }
31
+ ```
32
+
33
+ ### Feedback message
34
+
35
+ The variation also includes text that conveys feedback messages.
36
+
37
+ ```tsx
38
+ import React from "react";
39
+ import { Content } from "@jobber/components/Content";
40
+ import { Text } from "@jobber/components/Text";
41
+
42
+ export function TextFeedbackExample() {
43
+ return (
44
+ <Content>
45
+ <Text variation="success">Invoice sent</Text>
46
+ <Text variation="error">Name is required</Text>
47
+ <Text variation="warn">Your message is over 160 characters</Text>
48
+ <Text variation="info">
49
+ Drag to rearrange the order that the fields show up in Jobber
50
+ </Text>
51
+ </Content>
52
+ );
53
+ }
54
+ ```
55
+
56
+ ### Disabled
57
+
58
+ Use when the text is part of a disabled section of the interface.
59
+
60
+ Do not use `disabled` text to explain why an element is disabled. That text
61
+ should be default text with full intended contrast so that the user can clearly
62
+ identify why an element is disabled.
63
+
64
+ ```tsx
65
+ import React from "react";
66
+ import { Checkbox } from "@jobber/components/Checkbox";
67
+ import { Content } from "@jobber/components/Content";
68
+ import { Text } from "@jobber/components/Text";
69
+
70
+ export function TextDisabledExample() {
71
+ return (
72
+ <Content>
73
+ <div
74
+ style={{
75
+ display: "flex",
76
+ alignItems: "center",
77
+ gap: "var(--space-small)",
78
+ marginBottom: "var(--space-small)",
79
+ }}
80
+ >
81
+ <Checkbox disabled checked={false} />
82
+ <Text variation="disabled">A checkbox option</Text>
83
+ </div>
84
+ <Text>
85
+ You must enable your other settings before you can select this option.
86
+ </Text>
87
+ </Content>
88
+ );
89
+ }
90
+ ```
91
+
92
+ ## Alignment
93
+
94
+ Use left-aligned text for the the vast majority of use cases, particularly when
95
+ setting paragraphs. You may need to right-align text in cases where a label or
96
+ other small typographic element helps maintain vertical alignment on the right
97
+ side of a layout.
98
+
99
+ Centered text should be used sparingly, and largely in standalone cases like
100
+ empty states where the content is vertically and horizontally centered.
101
+
102
+ For text alignment, we use `start` and `end` instead of `left` and `right`. This
103
+ allows us to support
104
+ [bi-directionality](https://material.io/design/usability/bidirectionality.html#mirroring-layout)
105
+ when needed.
106
+
107
+ ```tsx
108
+ import React from "react";
109
+ import { Text } from "@jobber/components/Text";
110
+ import { ContentBlock } from "@jobber/components/ContentBlock";
111
+
112
+ export function TextAlignmentExample() {
113
+ return (
114
+ <ContentBlock maxWidth="100%">
115
+ <Text align="start">
116
+ Start aligns text to the left in Latin and other LTR scripts
117
+ </Text>
118
+ <Text align="center">Center is always in... the center</Text>
119
+ <Text align="end">
120
+ End aligns text to the right in Latin and other LTR scripts
121
+ </Text>
122
+ </ContentBlock>
123
+ );
124
+ }
125
+ ```
126
+
127
+ ## maxLines
128
+
129
+ Used to truncate large text with `...` based on line wrapping, such that the
130
+ total number of lines does not exceed the preset. This is an optional prop. If
131
+ left undefined all the contents are shown.
132
+
133
+ ```tsx
134
+ import React from "react";
135
+ import { Content } from "@jobber/components/Content";
136
+ import { Text } from "@jobber/components/Text";
137
+
138
+ export function TextMaxLinesExample() {
139
+ return (
140
+ <Content>
141
+ <Text maxLines="single">
142
+ This will show 1 line. Lorem ipsum dolor sit amet, consectetur
143
+ adipiscing elit. Vestibulum nec pulvinar nunc. Suspendisse nec eros
144
+ pretium, rutrum purus sit amet, finibus ante. Donec pretium condimentum
145
+ scelerisque.
146
+ </Text>
147
+ <Text maxLines="small">
148
+ This will show 2 lines. Lorem ipsum dolor sit amet, consectetur
149
+ adipiscing elit. Vestibulum nec pulvinar nunc. Suspendisse nec eros
150
+ pretium, rutrum purus sit amet, finibus ante. Donec pretium condimentum
151
+ scelerisque. Duis eu ligula nec metus suscipit feugiat.Etiam sapien
152
+ sapien, mattis eu tincidunt quis, pretium sed metus. Maecenas quis dolor
153
+ lacinia libero rhoncus fringilla. Cras mi ante, euismod nec tortor in,
154
+ tempus mollis nulla.
155
+ </Text>
156
+ <Text maxLines="base">
157
+ This will show 4 lines. Lorem ipsum dolor sit amet, consectetur
158
+ adipiscing elit. Vestibulum nec pulvinar nunc. Suspendisse nec eros
159
+ pretium, rutrum purus sit amet, finibus ante. Donec pretium condimentum
160
+ scelerisque. Duis eu ligula nec metus suscipit feugiat.Etiam sapien
161
+ sapien, mattis eu tincidunt quis, pretium sed metus. Maecenas quis dolor
162
+ lacinia libero rhoncus fringilla. Cras mi ante, euismod nec tortor in,
163
+ tempus mollis nulla.
164
+ </Text>
165
+ <Text maxLines="large">
166
+ This will show 8 lines. Lorem ipsum dolor sit amet, consectetur
167
+ adipiscing elit. Vestibulum nec pulvinar nunc. Suspendisse nec eros
168
+ pretium, rutrum purus sit amet, finibus ante. Donec pretium condimentum
169
+ scelerisque. Duis eu ligula nec metus suscipit feugiat.Etiam sapien
170
+ sapien, mattis eu tincidunt quis, pretium sed metus. Maecenas quis dolor
171
+ lacinia libero rhoncus fringilla. Cras mi ante, euismod nec tortor in,
172
+ tempus mollis nulla. Etiam eu lacus nibh. Donec tristique lacus magna,
173
+ vulputate tristique lacus blandit vitae. Aenean vitae commodo metus.
174
+ Fusce eu risus quis orci pharetra consequat nec nec libero.
175
+ </Text>
176
+ <Text maxLines="larger">
177
+ This will show 16 lines. Lorem ipsum dolor sit amet, consectetur
178
+ adipiscing elit. Vestibulum nec pulvinar nunc. Suspendisse nec eros
179
+ pretium, rutrum purus sit amet, finibus ante. Donec pretium condimentum
180
+ scelerisque. Duis eu ligula nec metus suscipit feugiat.Etiam sapien
181
+ sapien, mattis eu tincidunt quis, pretium sed metus. Maecenas quis dolor
182
+ lacinia libero rhoncus fringilla. Cras mi ante, euismod nec tortor in,
183
+ tempus mollis nulla. Etiam eu lacus nibh. Donec tristique lacus magna,
184
+ vulputate tristique lacus blandit vitae. Aenean vitae commodo metus.
185
+ Fusce eu risus quis orci pharetra consequat nec nec libero. Lorem ipsum
186
+ dolor sit amet, consectetur adipiscing elit. Vestibulum nec pulvinar
187
+ nunc. Suspendisse nec eros pretium, rutrum purus sit amet, finibus ante.
188
+ Donec pretium condimentum scelerisque. Duis eu ligula nec metus suscipit
189
+ feugiat.Etiam sapien sapien, mattis eu tincidunt quis, pretium sed
190
+ metus. Maecenas quis dolor lacinia libero rhoncus fringilla. Cras mi
191
+ ante, euismod nec tortor in, tempus mollis nulla. Etiam eu lacus nibh.
192
+ Donec tristique lacus magna, vulputate tristique lacus blandit vitae.
193
+ Aenean vitae commodo metus. Fusce eu risus quis orci pharetra consequat
194
+ nec nec libero.
195
+ </Text>
196
+ </Content>
197
+ );
198
+ }
199
+ ```
200
+
201
+ ## Platform Considerations (Web)
202
+
203
+ ### Sizes
204
+
205
+ Text can be used with different sizes.
206
+
207
+ ```tsx
208
+ import React from "react";
209
+ import { Content } from "@jobber/components/Content";
210
+ import { Text } from "@jobber/components/Text";
211
+
212
+ export function TextSizesExample() {
213
+ return (
214
+ <Content>
215
+ <Text size="base">
216
+ Both Trains and Text come in all different kinds of sizes
217
+ </Text>
218
+ <Text size="small">Sometimes they are small</Text>
219
+ <Text size="large">Other times they are large</Text>
220
+ </Content>
221
+ );
222
+ }
223
+ ```
224
+
225
+ #### Base
226
+
227
+ Base is the default size and is optimized for the widest range of uses,
228
+ including:
229
+
230
+ * Long paragraphs of text content
231
+ * Descriptions of subsequent UI elements
232
+ * Labels on UI elements such as checkboxes and radio buttons
233
+ * Freeform user-generated content
234
+
235
+ #### Large
236
+
237
+ Typically large is to be used as an introductory paragraph that gives important
238
+ information about a page, and requires greater prominence.
239
+
240
+ #### Small
241
+
242
+ The small size is intended to be used as helper content on things like
243
+ checkboxes, radio buttons, inputs or any other UI elements that need help
244
+ provided.
245
+
246
+
247
+ ## Component customization
248
+
249
+ ### UNSAFE\_ props (advanced usage)
250
+
251
+ General information for using `UNSAFE_` props can be found
252
+ [here](../customizing-components/customizing-components.md).
253
+
254
+ **Note**: Use of `UNSAFE_` props is **at your own risk** and should be
255
+ considered a **last resort**. Future Text updates may lead to unintended
256
+ breakages.
257
+
258
+ #### UNSAFE\_ props (web)
259
+
260
+ ### UNSAFE\_className
261
+
262
+ Use `UNSAFE_className` to apply custom classes to the Text component. This
263
+ can be useful for applying styles via CSS Modules.
264
+
265
+ ```tsx
266
+ // YourComponent.tsx
267
+ <Text UNSAFE_className={{ textStyle: styles.customText }}>
268
+ Custom text style
269
+ </Text>
270
+
271
+ // YourComponent.module.css
272
+ .customText {
273
+ color: var(--color-purple);
274
+ }
275
+ ```
276
+
277
+ ### UNSAFE\_style
278
+
279
+ Use `UNSAFE_style` to apply inline custom styles to the Text component.
280
+
281
+ ```tsx
282
+ <Text UNSAFE_style={{ textStyle: { color: "var(--color-purple)" } }}>
283
+ Custom text style
284
+ </Text>
285
+ ```
286
+
287
+ #### UNSAFE\_style (mobile)
288
+
289
+ The mobile Text component can be custom styled using the `textStyle` type via
290
+ the `UNSAFE_style` prop.
291
+
292
+ React Native does not support className. Instead, you can use `UNSAFE_style` to
293
+ apply styles either inline or through a StyleSheet.
294
+
295
+ ##### Inline styles
296
+
297
+ ```tsx
298
+ UNSAFE_style={{ textStyle: { color: tokens["color-purple--light"] } }}
299
+ ```
300
+
301
+ ##### StyleSheet
302
+
303
+ ```tsx
304
+ // Text.tsx
305
+ UNSAFE_style={{
306
+ textStyle: styles.customTextStyle,
307
+ }}
308
+
309
+ // Text.style.ts
310
+ export const styles = StyleSheet.create({
311
+ customTextStyle: {
312
+ color: tokens["color-purple--light"],
313
+ },
314
+ });
315
+ ```
316
+
317
+ ## Platform Considerations (Mobile)
318
+
319
+ ### Notes
320
+
321
+ Text uses the core component [Text](https://reactnative.dev/docs/text) from
322
+ `react-native`.
323
+
324
+ #### Nested text (mobile)
325
+
326
+ The mobile `Text` component now supports nested children like React Native’s
327
+ `Text`. You can compose inline layouts and mixed formatting:
328
+
329
+ ```tsx
330
+ <Text>
331
+ Normal <Text emphasis="strong">Bold</Text> and
332
+ <Text italic> italic</Text> text
333
+ </Text>
334
+ ```
335
+
336
+ Transforms (e.g., `transform="uppercase"`) apply only to string children of the
337
+ component they are set on. Nested `Text`/`Typography` elements can set their own
338
+ `transform` independently.
339
+
340
+ ### Copying text
341
+
342
+ There are a few caveats around copying text on Android and iOS that you can read
343
+ under the [Typography](../Typography/Typography.md) documentation.
344
+
345
+
346
+ ## Props
347
+
348
+ ### Mobile
349
+
350
+ | Prop | Type | Required | Default | Description |
351
+ |------|------|----------|---------|-------------|
352
+ | `adjustsFontSizeToFit` | `boolean` | No | `false` | Determines whether text should be scaled down to fit based on maxLines prop |
353
+ | `align` | `TextAlign` | No | — | Alignment of text |
354
+ | `allowFontScaling` | `boolean` | No | `true` | Allow text to be resized based on user's device display scale |
355
+ | `children` | `ReactNode` | No | — | Text to display. Supports nesting text elements. |
356
+ | `emphasis` | `"strong"` | No | — | Change the appearance of the text |
357
+ | `hideFromScreenReader` | `boolean` | No | `false` | This will make the text inaccessible to the screen reader. This should be avoided unless there is a good reason. For ... |
358
+ | `italic` | `boolean` | No | `false` | Use italic font style |
359
+ | `level` | `TextLevel` | No | `text` | Visual hierarchy of the text |
360
+ | `maxFontScaleSize` | `number` | No | — | Set the maximum font the text can go to size when the user scales their device font size |
361
+ | `maxLines` | `TruncateLength` | No | `unlimited` | The maximum amount of lines the text can occupy before being truncated with "...". Uses predefined string values that... |
362
+ | `onTextLayout` | `(event: TextLayoutEvent) => void` | No | — | Callback that is called when the text is laid out. |
363
+ | `reverseTheme` | `boolean` | No | `false` | Reverse theme for better display on dark background |
364
+ | `selectable` | `boolean` | No | `true` | Lets the user select text, to use the native copy and paste functionality. WARNING: if true, this prevents ellipsis f... |
365
+ | `strikeThrough` | `boolean` | No | `false` | Have text styled with strike through |
366
+ | `underline` | `"solid" | "dotted"` | No | — | Underline style to use for the text. The non-solid style is only supported on iOS, as per React Native's Text compone... |
367
+ | `UNSAFE_style` | `TypographyUnsafeStyle` | No | — | **Use at your own risk:** Custom style for specific elements. This should only be used as a **last resort**. Using th... |
368
+ | `variation` | `TextVariation` | No | `base` | Color variation of text |
@@ -0,0 +1,29 @@
1
+ # TextList
2
+
3
+ The TextList is a component that displays a text of unordered list.
4
+
5
+ ## Design & usage guidelines
6
+
7
+ Utilizing TextList is quite simple - it should typically appear following any
8
+ relevant text or content. TextList manages the presentation of a list of text
9
+ items, rendering them in a clear, organized bullet-point format. It aids in
10
+ making the content easily digestible for the user.
11
+
12
+ ## Related components
13
+
14
+ This component is uses the [Content](../Content/Content.md) and
15
+ [Text](../Text/Text.md) components for displaying. This is also used for
16
+ displaying the error list in [Banner](../Banner/Banner.md) component.
17
+
18
+
19
+ ## Props
20
+
21
+ ### Mobile
22
+
23
+ | Prop | Type | Required | Default | Description |
24
+ |------|------|----------|---------|-------------|
25
+ | `childSpacing` | `Spacing` | No | `none` | The amount of spacing that will be applied between the list items. |
26
+ | `emphasis` | `"strong"` | No | — | Change the appearance of the text |
27
+ | `items` | `string[]` | No | — | Text to display. |
28
+ | `level` | `TextLevel` | No | `text` | Visual hierarchy of the text. |
29
+ | `spacing` | `Spacing` | No | `none` | The amount of spacing that content will give. |
@@ -0,0 +1,16 @@
1
+ # Thumbnail List
2
+
3
+ For guidelines on using this component, see the documentation for web equivalent
4
+ component, [Gallery](/components/Gallery).
5
+
6
+
7
+ ## Props
8
+
9
+ ### Mobile
10
+
11
+ | Prop | Type | Required | Default | Description |
12
+ |------|------|----------|---------|-------------|
13
+ | `files` | `File[]` | Yes | — | |
14
+ | `createThumbnail` | `CreateThumbnail` | No | — | |
15
+ | `handleOpenFile` | `({ file, index, imageList, }: { file: File; index: number; imageList: File[]; }) => void` | No | — | |
16
+ | `rowCount` | `RowCount` | No | `RowCount.TwoRows` | |
@@ -0,0 +1,71 @@
1
+ # Toast
2
+
3
+ Toasts are short, temporary messages used to inform users that a process was
4
+ performed. They provide visual feedback on the outcome of an action and require
5
+ minimal user interaction.
6
+
7
+ Toast, unlike common React components, is not a component that will be added to
8
+ your view. Instead, Toast is used by importing and calling the `showToast()`
9
+ function.
10
+
11
+ ## Design & usage guidelines
12
+
13
+ Use `Toast` to present non-blocking feedback about the system to a user.
14
+
15
+ ### Related components
16
+
17
+ For more persistent feedback (such as displaying errors), communicating a
18
+ background process that is ongoing, or for feedback that has a longer reading
19
+ length or CTA, use [Banner.](../Banner/Banner.md)
20
+
21
+ ### Variation (Web only)
22
+
23
+ The primary use case for Toast is success messages.
24
+
25
+ In some cases, an informational Toast may be used to inform the user of some
26
+ background system activity. See
27
+ [Web/Info example](/storybook/web/?path=/story/components-status-and-feedback-toast--variation)
28
+
29
+ ### Errors
30
+
31
+ > Do not use Toast for errors. This is currently an available variation, but
32
+ > should be considered deprecated and not propagated.
33
+
34
+ Use [Banner](../Banner/Banner.md) and, where necessary, targeted error messaging
35
+ (such as [InputValidation](/components/InputValidation)) so that the user can
36
+ appropriately assess and recover from the error.
37
+
38
+ ## Content guidelines
39
+
40
+ The Toast label should be clear and concise, and should not take up more than
41
+ one line.
42
+
43
+ Use the pattern "action + subject" to maintain
44
+ [active voice](/content/voice-and-tone). The subject should be specific without
45
+ overloading too much detail for the user to parse at a quick glance.
46
+
47
+ | ✅ Do | ❌ Don't |
48
+ | ----------------- | -------------------------------------------------- |
49
+ | Saved job | Saved job #216 - Weekly mowing for Nathaniel Lewis |
50
+ | Archived property | Archived 289 NW 198th St, Shoreline, WA 98177, USA |
51
+
52
+ * No need to use "Successfully", should be implicit in the Toast
53
+ * Don't use `Dismiss` or `Cancel` as an action label
54
+ * Examples of action labels: `Undo`, `View`, `Refresh`
55
+ * Toast's label does not require a period
56
+ * Use sentence case, and only capitalize
57
+ ["branded"](/content/product-vocabulary) Jobber features
58
+
59
+ | ✅ Do | ❌ Don't |
60
+ | ---------- | ----------------------- |
61
+ | Saved job | Saved Job Successfully. |
62
+ | Sent quote | Sent Quote |
63
+
64
+
65
+ ## Props
66
+
67
+ ### Mobile
68
+
69
+ | Prop | Type | Required | Default | Description |
70
+ |------|------|----------|---------|-------------|
71
+ | `bottomOffset` | `number` | No | `40` | Offset from the bottom of the screen in px. Has effect only when the position is "bottom". |
@@ -0,0 +1,170 @@
1
+ # Typography
2
+
3
+ When a designer is talking about "type", it's unlikely they're asking about the
4
+ latest Typescript linting rules! Typography is a core aspect of any user
5
+ interface, and we've built a system that should make it simple for our
6
+ interfaces to be built with consistent, considered typographic elements.
7
+
8
+ The Atlantis typography system is based on the core components of
9
+ [Heading](../Heading/Heading.md) and [Text](../Text/Text.md).
10
+
11
+ ```tsx
12
+ <Content>
13
+ <Heading level={1} element="h2">
14
+ A <Emphasis variation="highlight">prominent</Emphasis> heading
15
+ </Heading>
16
+ <Text>
17
+ A longer body of text that&apos;s better suited for readabilty at smaller
18
+ sizes. Typically a paragraph should be displayed in a typeface that has a
19
+ moderate weight, and is <Emphasis variation="italic">relatively</Emphasis>{" "}
20
+ free of flourish.
21
+ </Text>
22
+ </Content>
23
+ ```
24
+
25
+ Heading and Text are extended by the ability to add
26
+ [Emphasis](/components/Emphasis) to these components as needed.
27
+
28
+ There are some foundational elements that make up these components:
29
+
30
+ ## Font families
31
+
32
+ ### Display
33
+
34
+ Jobber Pro is Jobber's internal typeface and is only suitable for use in Jobber
35
+ products. It lends a hefty-but-professional face to larger usages such as page
36
+ titles.
37
+
38
+ As Jobber Pro is a custom typeface licensed specifically for Jobber usage, it
39
+ will be rendered in any environments where it is licensed for use. In external
40
+ usages, [Poppins](https://fonts.google.com/specimen/Poppins) is Atlantis'
41
+ fallback display face. It has similar structural features and optical sizing as
42
+ Jobber Pro.
43
+
44
+ ```tsx
45
+ <Content>
46
+ <Heading level={1}>Jobber Pro is used for page titles</Heading>
47
+ </Content>
48
+ ```
49
+
50
+ ### Base
51
+
52
+ [Inter](https://fonts.google.com/specimen/Inter) is our most broadly-used
53
+ typeface. It is used for body copy, most headings, data display, form inputs,
54
+ labels, and more!
55
+
56
+ ```tsx
57
+ <Content spacing="large">
58
+ <Heading level={3}>Inter is for less prominent headings</Heading>
59
+ <Text>
60
+ You can also use it for longer, more readable statements in paragraphs,
61
+ descriptive text, in lists, and more. If you&apos;ve been paying careful
62
+ attention, you might have noticed that Atlantis even uses Inter for
63
+ presenting documentation!
64
+ </Text>
65
+ <Checkbox checked label="Inter can label inputs nicely"></Checkbox>
66
+ <InputText
67
+ defaultValue="It's great for input values too"
68
+ placeholder="Inter for labels"
69
+ />
70
+ <Table>
71
+ <Header>
72
+ <Cell>Inter</Cell>
73
+ <Cell>Renders</Cell>
74
+ <Cell align="right">Data</Cell>
75
+ </Header>
76
+ <Body>
77
+ <Row>
78
+ <Cell>Data point</Cell>
79
+ <Cell>More data</Cell>
80
+ <Cell align="right">$280</Cell>
81
+ </Row>
82
+ <Row>
83
+ <Cell>Another data point</Cell>
84
+ <Cell>Additional values</Cell>
85
+ <Cell align="right">$200</Cell>
86
+ </Row>
87
+ </Body>
88
+ </Table>
89
+ </Content>
90
+ ```
91
+
92
+ ## Font-size
93
+
94
+ ### Web
95
+
96
+ At the default zoom level for web applications, our base font-size is equivalent
97
+ to `14px`. Depending on the context in which your typography is being used,
98
+ font-size can be adjusted to be larger or smaller than the base font-size.
99
+
100
+ Suggestions for when to use varying font-sizes are discussed in the
101
+ [Heading](../Heading/Heading.md) component, and within the
102
+ [Sizes](../Text/Text.md) section of the Text component.
103
+
104
+ | Name | Visual | Value |
105
+ | :----------------------------------- | :----- | :---- |
106
+ | `--typography--fontSize-smaller` | | |
107
+ | `--typography--fontSize-small` | | |
108
+ | `--typography--fontSize-base` | | |
109
+ | `--typography--fontSize-large` | | |
110
+ | `--typography--fontSize-larger` | | |
111
+ | `--typography--fontSize-largest` | | |
112
+ | `--typography--fontSize-jumbo` | | |
113
+ | `--typography--fontSize-extravagant` | | |
114
+
115
+ ### Mobile
116
+
117
+ Jobber's mobile platform uses the following sizing tokens for typography.
118
+
119
+ The mobile platform has a base font-size equivalent to `16px`, with options for
120
+ a larger or smaller font-size depending on the use case.
121
+
122
+ | Name | Visual | Value |
123
+ | :----------------------------------- | :----- | :---- |
124
+ | `--typography--fontSize-smallest` | | |
125
+ | `--typography--fontSize-smaller` | | |
126
+ | `--typography--fontSize-small` | | |
127
+ | `--typography--fontSize-base` | | |
128
+ | `--typography--fontSize-large` | | |
129
+ | `--typography--fontSize-larger` | | |
130
+ | `--typography--fontSize-largest` | | |
131
+ | `--typography--fontSize-jumbo` | | |
132
+ | `--typography--fontSize-extravagant` | | |
133
+
134
+ ## Line-height
135
+
136
+ ### Web
137
+
138
+ Line-height, or
139
+ [leading](https://www.shillingtoneducation.com/blog/leading-typography/), is the
140
+ space between subsequent lines of type. The line-heights in the `Heading` and
141
+ `Text` components are optimized for each variation's unique combination of
142
+ font-size, weight, and family, so you don't need to adjust their line-height
143
+ manually when you use them.
144
+
145
+ At smaller sizes, a more generous line-height relative to the font-size allows
146
+ the user to more easily parse multiple lines of small text. As font-size
147
+ increases into "display" sizes such as a level 1 `Heading`, the ratio of
148
+ line-height to font-size decreases as the larger font-size is more readable and
149
+ requires less line-to-line breathing room.
150
+
151
+ | Name | Visual | Value |
152
+ | :----------------------------------- | :----- | :---- |
153
+ | `--typography--lineHeight-large` | | |
154
+ | `--typography--lineHeight-base` | | |
155
+ | `--typography--lineHeight-tight` | | |
156
+ | `--typography--lineHeight-tighter` | | |
157
+ | `--typography--lineHeight-tightest` | | |
158
+ | `--typography--lineHeight-minuscule` | | |
159
+
160
+ ### Mobile
161
+
162
+ | Name | Visual | Value |
163
+ | :------------------------------------- | :----- | :---- |
164
+ | `--typography--lineHeight-extravagant` | | |
165
+ | `--typography--lineHeight-jumbo` | | |
166
+ | `--typography--lineHeight-largest` | | |
167
+ | `--typography--lineHeight-larger` | | |
168
+ | `--typography--lineHeight-large` | | |
169
+ | `--typography--lineHeight-base` | | |
170
+ | `--typography--lineHeight-tight` | | |