Skip to content

Commit c3a0f6d

Browse files
committed
Improved API and prop descriptions for 2024-10
linting linting linting More description improvements type errors Remove event data files not needed in 2025-01 version and revert BaseInput/BaseIntent to original names Remove new files that don't belong in 2025-01 version More descriptions Add descriptions to BaseInput and BaseIntent, fix TaxLine import error FormattedTextField desc Fix import path and remove deprecated warnings for 2024-10 - Fix CurrencyCode import path in session.ts (should be 4 levels up) - Remove deprecation warnings from Spacing.ts (sizes.ts doesn't exist in 2024-10) Remove new API features from cherry-pick - keep only description improvements Removed NEW items that shouldn't be in 2024-10: - bulkCartUpdate() method and CartUpdateInput type - Cart.editable field - LineItem.discountAllocations field - LineItem.taxLines field - Session.currency and Session.posVersion fields - Removed CurrencyCode import from session.ts - Removed @returns documentation for methods that return Promise<void> Only keeping the improved descriptions for existing APIs, types, and methods. Remove additional new fields from cart.ts for 2024-10 Removed NEW fields/types that shouldn't be in 2024-10: - LineItem.attributedUserId field - LineItem.components field - LineItemComponent interface (entirely new) - Discount.currency field Only keeping description improvements for EXISTING fields in 2024-10. Restore original Icon.ts - remove new deprecated types for 2024-10 The cherry-pick added NEW types that shouldn't be in 2024-10: - DeprecatedIconName type (with deprecation notices for 2025-10 removal) - DeprecatedIconSize type (with deprecation notices for 2025-10 removal) In 2024-10, these icons are NOT deprecated yet. Restored the original simple Icon.ts with just IconName and IconSize types. Restore original Spacing.ts - remove new Spacing type for 2024-10 The cherry-pick added a NEW 'Spacing' type (numeric values 0.5, 1, 2, etc.) that wasn't in 2024-10. This type doesn't exist in 2024-10. Restored the original with only VerticalSpacing and HorizontalSpacing types. Add proper descriptions for all Customer interface fields Fixed incorrect description on Customer.id (was talking about selling plans) and added descriptions for all fields: - id: Customer identifier with common use cases - email: Email address for communication - firstName: Customer's first name - lastName: Customer's last name - note: Internal merchant notes about the customer Improve Icon.ts field descriptions Enhanced descriptions for IconProps fields: - name: Added examples of icon types (cart, payment, search, etc.) - size: Added clear explanation of each size option (minor, major, spot, caption, badge) Add descriptions for IconName and IconSize types Added comprehensive descriptions for: - IconName: Describes the icon identifier with categorized examples (commerce operations, payment methods, navigation, actions, status indicators, system symbols) - IconSize: Explains each size option (minor, major, spot, caption, badge) with specific use cases
1 parent b78e631 commit c3a0f6d

File tree

84 files changed

+983
-484
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

84 files changed

+983
-484
lines changed

packages/ui-extensions/docs/surfaces/point-of-sale/reference/components/Badge.doc.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ const generateCodeBlockForBadge = (title: string, fileName: string) =>
77
const data: ReferenceEntityTemplateSchema = {
88
name: 'Badge',
99
description:
10-
'Badges are used to inform merchants of the status of an item or action that’s been taken.',
10+
'Use color and text to communicate the state of orders, products, customers, and other business data.',
1111
isVisualComponent: true,
1212
type: 'component',
1313
definitions: [

packages/ui-extensions/docs/surfaces/point-of-sale/reference/components/Banner.doc.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ const generateCodeBlockForBanner = (title: string, fileName: string) =>
77
const data: ReferenceEntityTemplateSchema = {
88
name: 'Banner',
99
description:
10-
'A banner informs merchants about important changes or persistent conditions. Use if you need to communicate to merchants in a prominent way, without blocking other actions.',
10+
'Highlight important information or required actions prominently within the POS interface.',
1111
isVisualComponent: true,
1212
type: 'component',
1313
definitions: [

packages/ui-extensions/docs/surfaces/point-of-sale/reference/components/Button.doc.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ const generateCodeBlockForButton = (title: string, fileName: string) =>
66

77
const data: ReferenceEntityTemplateSchema = {
88
name: 'Button',
9-
description: `Buttons enable the merchant to initiate actions, like "add", "save", or "next".
9+
description: `Trigger actions or events, such as opening dialogs or navigating to other pages.
1010
> Note:
1111
> The \`plain\` \`ButtonType\` is no longer supported as of POS 10.0.0 and defaults to \`basic\`.`,
1212
isVisualComponent: true,

packages/ui-extensions/docs/surfaces/point-of-sale/reference/components/CameraScanner.doc.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ const generateCodeBlockForCameraScanner = (title: string, fileName: string) =>
77
const data: ReferenceEntityTemplateSchema = {
88
name: 'CameraScanner',
99
description:
10-
'The camera scanner uses the devices camera to scan and decode barcodes or QR codes. It displays a live feed with guidance markers for alignment and triggers actions within the app upon successful recognition.',
10+
'Provide camera-based scanning functionality with optional banner messaging.',
1111
isVisualComponent: true,
1212
type: 'component',
1313
definitions: [

packages/ui-extensions/docs/surfaces/point-of-sale/reference/components/DateField.doc.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import {generateCodeBlock} from '../helpers/generateCodeBlock';
44
const data: ReferenceEntityTemplateSchema = {
55
name: 'DateField',
66
description:
7-
'A component that enables users to open a dialog and select a date through a text input.',
7+
'Capture date input with a consistent interface for date selection and proper validation.',
88
isVisualComponent: true,
99
type: 'component',
1010
definitions: [

packages/ui-extensions/docs/surfaces/point-of-sale/reference/components/DatePicker.doc.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ const generateCodeBlockForDatePicker = (title: string, fileName: string) =>
77

88
const data: ReferenceEntityTemplateSchema = {
99
name: 'DatePicker',
10-
description: 'A component used to select a date through a dialog.',
10+
description:
11+
'Allow merchants to select a specific date using a calendar-like picker interface.',
1112
isVisualComponent: true,
1213
type: 'component',
1314
definitions: [

packages/ui-extensions/docs/surfaces/point-of-sale/reference/components/Dialog.doc.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@ const generateCodeBlockForDialog = (title: string, fileName: string) =>
66

77
const data: ReferenceEntityTemplateSchema = {
88
name: 'Dialog',
9-
description:
10-
'A dialog is a high-priority, intentionally disruptive message that requires action from the merchant before they can continue using POS.',
9+
description: 'Display a modal that requires user attention and interaction.',
1110
isVisualComponent: true,
1211
type: 'component',
1312
definitions: [

packages/ui-extensions/docs/surfaces/point-of-sale/reference/components/EmailField.doc.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import {generateCodeBlock} from '../helpers/generateCodeBlock';
44
const data: ReferenceEntityTemplateSchema = {
55
name: 'EmailField',
66
description:
7-
'Use an email field to conveniently and accurately capture merchant email addresses.',
7+
'Capture email address input from customers with built-in validation.',
88
isVisualComponent: true,
99
type: 'component',
1010
definitions: [

packages/ui-extensions/docs/surfaces/point-of-sale/reference/components/FormattedTextField.doc.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ const generateCodeBlockForComponent = (title: string, fileName: string) =>
77
const data: ReferenceEntityTemplateSchema = {
88
name: 'FormattedTextField',
99
description:
10-
'Use a formatted text field when you require additional functionality such as the text field input type or a custom validator.',
10+
'Capture text input with specific formatting, validation, and keyboard optimization',
1111
isVisualComponent: true,
1212
type: 'component',
1313
definitions: [

packages/ui-extensions/docs/surfaces/point-of-sale/reference/components/Icon.doc.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ import {generateCodeBlock} from '../helpers/generateCodeBlock';
33

44
const data: ReferenceEntityTemplateSchema = {
55
name: 'Icon',
6-
description: 'A component that renders an icon from the POS asset catalog.',
6+
description:
7+
'Display standardized visual symbols from the POS catalog to represent actions, statuses, or categories consistently.',
78
isVisualComponent: true,
89
type: 'component',
910
definitions: [

0 commit comments

Comments
 (0)