@primer-io/primer-js 0.2.0 → 0.3.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.
Files changed (60) hide show
  1. package/dist/chunks/{ar.6MRFCKX4.js → ar.KRXB3WQO.js} +1 -1
  2. package/dist/chunks/{bg.HRSMU7Y5.js → bg.6SKJRXIR.js} +1 -1
  3. package/dist/chunks/{ca.3FSHJL7U.js → ca.SANDLFEK.js} +1 -1
  4. package/dist/chunks/chunk.DV3REKZU.js +1 -0
  5. package/dist/chunks/{cs.WAO4WFS3.js → cs.FC4I5M3C.js} +1 -1
  6. package/dist/chunks/{da.4OFYGDVA.js → da.YI32NZ7B.js} +1 -1
  7. package/dist/chunks/{de.3FZS52IN.js → de.7M7UFQB7.js} +1 -1
  8. package/dist/chunks/{el.A4R7VG5T.js → el.XSGTYDZR.js} +1 -1
  9. package/dist/chunks/en-GB.VO4GDE3X.js +1 -0
  10. package/dist/chunks/en.MNFLVOE3.js +1 -0
  11. package/dist/chunks/{es-AR.QKHDL4JV.js → es-AR.TBWVUZEF.js} +1 -1
  12. package/dist/chunks/{es-MX.GG7MJMG2.js → es-MX.6EMWUABR.js} +1 -1
  13. package/dist/chunks/{es.FEZ6BF3S.js → es.XZLDFHYI.js} +1 -1
  14. package/dist/chunks/{et-EE.FJLPTMF3.js → et-EE.JBSFMKZ2.js} +1 -1
  15. package/dist/chunks/{fi-FI.DM5R27A5.js → fi-FI.I75VK2ID.js} +1 -1
  16. package/dist/chunks/{fr.YZV52NTA.js → fr.JBNP6RXT.js} +1 -1
  17. package/dist/chunks/{he.6SCF3XZZ.js → he.PW253QAL.js} +1 -1
  18. package/dist/chunks/{hr.PPDZ7AAS.js → hr.LM4RITYJ.js} +1 -1
  19. package/dist/chunks/{hu.6WOPSGLW.js → hu.JGCKQA6J.js} +1 -1
  20. package/dist/chunks/{id.NS22WGWL.js → id.VBXULDDY.js} +1 -1
  21. package/dist/chunks/{it.42TO3R4G.js → it.7Q6BFLDK.js} +1 -1
  22. package/dist/chunks/{ja.UEGHEUAP.js → ja.QOC76SSC.js} +1 -1
  23. package/dist/chunks/{ko.HTMDY6RY.js → ko.BANZIFNH.js} +1 -1
  24. package/dist/chunks/{lt-LT.4U3GBQTQ.js → lt-LT.Q2SRJOKH.js} +1 -1
  25. package/dist/chunks/{lt.73ME4TDM.js → lt.XMNFEN5T.js} +1 -1
  26. package/dist/chunks/{lv-LV.JRWO2BF6.js → lv-LV.3AJDTMU5.js} +1 -1
  27. package/dist/chunks/{lv.KROS45TV.js → lv.TFPDXNEV.js} +1 -1
  28. package/dist/chunks/{ms.HE3SWJFQ.js → ms.FPTX4NM4.js} +1 -1
  29. package/dist/chunks/{nb.TR6TEKBY.js → nb.CAFSKRQ2.js} +1 -1
  30. package/dist/chunks/{nl.V5QP6OXL.js → nl.7BPSDYTC.js} +1 -1
  31. package/dist/chunks/{nl_NL.FCVWIF3Y.js → nl_NL.6ZVCFPVW.js} +1 -1
  32. package/dist/chunks/{pl.DQZDG7LR.js → pl.RF34QM23.js} +1 -1
  33. package/dist/chunks/{pt-BR.CR4ROBVE.js → pt-BR.AKDHLRUA.js} +1 -1
  34. package/dist/chunks/{pt.JRWVFJPX.js → pt.VBALOWHZ.js} +1 -1
  35. package/dist/chunks/{ro.NRMWYY3F.js → ro.WN7VCF27.js} +1 -1
  36. package/dist/chunks/{ru.OWSKHXVO.js → ru.ICXGVGRR.js} +1 -1
  37. package/dist/chunks/{sk.YGBRNNWT.js → sk.SIP5JIOX.js} +1 -1
  38. package/dist/chunks/{sl.IRTDTNTP.js → sl.R77UEKCA.js} +1 -1
  39. package/dist/chunks/{sr-RS.AWGLHKVE.js → sr-RS.6M2YSTDX.js} +1 -1
  40. package/dist/chunks/{sv.O4BXFGNF.js → sv.33ZY4CDS.js} +1 -1
  41. package/dist/chunks/{th.GZCEBRT2.js → th.M27YUIZC.js} +1 -1
  42. package/dist/chunks/{tr.ZDILMEEO.js → tr.Q2SIY6NA.js} +1 -1
  43. package/dist/chunks/{uk-UA.JUUBOEW3.js → uk-UA.EJZOGSJR.js} +1 -1
  44. package/dist/chunks/{vi.IN7CFTLL.js → vi.3RROGLXM.js} +1 -1
  45. package/dist/chunks/zf.GGWFQ3Y7.js +1 -0
  46. package/dist/chunks/{zh-CN.RBRAS4RP.js → zh-CN.MQHNRMN4.js} +1 -1
  47. package/dist/chunks/{zh-HK.4CK7LBWM.js → zh-HK.WNR7XUSX.js} +1 -1
  48. package/dist/chunks/{zh-TW.374TMWNJ.js → zh-TW.GNCY2PNY.js} +1 -1
  49. package/dist/custom-elements.json +1314 -843
  50. package/dist/jsx/index.d.ts +85 -87
  51. package/dist/primer-loader.d.ts +852 -2484
  52. package/dist/primer-loader.js +138 -2662
  53. package/dist/primer-react-wrappers.js +121 -2106
  54. package/dist/vscode.html-custom-data.json +54 -30
  55. package/dist/web-types.json +195 -117
  56. package/package.json +7 -2
  57. package/dist/chunks/chunk.I6YWTZRK.js +0 -1
  58. package/dist/chunks/en-GB.ILZ7SXSW.js +0 -1
  59. package/dist/chunks/en.7GZJA7MN.js +0 -1
  60. package/dist/chunks/zf.YT47ULXR.js +0 -1
@@ -6,11 +6,12 @@
6
6
  "name": "primer-checkout",
7
7
  "description": "PrimerCheckoutComponent implements the main checkout experience.\nThis component includes a CSS-only loader that displays before the JavaScript\nis fully loaded, ensuring users see a loading indicator immediately.\n\nThe loader can be disabled by:\n1. Adding the 'loader-disabled' attribute to the component\n2. Setting the CSS custom property --primer-loader-disabled: 1\n---\n",
8
8
  "attributes": [
9
- { "name": "customStyles", "values": [] },
10
- { "name": "clientToken", "values": [] },
9
+ { "name": "custom-styles", "values": [] },
10
+ { "name": "client-token", "values": [] },
11
11
  { "name": "options", "values": [{ "name": "PrimerCheckoutOptions" }] },
12
+ { "name": "loader-disabled", "values": [] },
12
13
  {
13
- "name": "_jsInitialized",
14
+ "name": "js-initialized",
14
15
  "description": "Whether the component has completed initialization and loading\nThis is used to control the CSS-only loader visibility",
15
16
  "values": []
16
17
  }
@@ -19,7 +20,7 @@
19
20
  },
20
21
  {
21
22
  "name": "primer-button",
22
- "description": "\n---\n\n\n### **Events:**\n - **selection-change**",
23
+ "description": "\n---\n",
23
24
  "attributes": [
24
25
  {
25
26
  "name": "variant",
@@ -54,6 +55,11 @@
54
55
  "name": "selectable",
55
56
  "description": "Indicates if this button is selectable/checkable",
56
57
  "values": []
58
+ },
59
+ {
60
+ "name": "flex",
61
+ "description": "Indicates if wraps the slot in a flex container",
62
+ "values": []
57
63
  }
58
64
  ],
59
65
  "references": []
@@ -109,7 +115,7 @@
109
115
  },
110
116
  {
111
117
  "name": "primer-dialog",
112
- "description": "\n---\n\n\n### **Events:**\n - **primer-dialog-close**",
118
+ "description": "\n---\n",
113
119
  "attributes": [],
114
120
  "references": []
115
121
  },
@@ -129,7 +135,7 @@
129
135
  },
130
136
  {
131
137
  "name": "role",
132
- "description": "Accessibility role for the error message\nDefaults to \"alert\" for proper screen reader announcements",
138
+ "description": "Accessibility role (defaults to \"alert\")",
133
139
  "values": []
134
140
  }
135
141
  ],
@@ -154,7 +160,7 @@
154
160
  },
155
161
  {
156
162
  "name": "primer-input",
157
- "description": "A fully type-safe input component that wraps the native HTML input element\nwhile providing additional functionality and styling.\n---\n\n\n### **Events:**\n - **focus** - Fired when the input receives focus\n- **blur** - Fired when the input loses focus\n- **invalid** - Fired when the input fails validation\n- **input** - Fired when the input value changes\n- **change** - Fired when the input value is committed\n\n### **Methods:**\n - **focus(options: _FocusOptions_): _void_** - Focus the input element\n- **blur(): _void_** - Remove focus from the input element\n- **select(): _void_** - Select all text in the input element\n- **setSelectionRange(start: _number_, end: _number_, direction: _'forward' | 'backward' | 'none'_): _void_** - Set the selection range of the input element\n- **checkValidity(): _boolean_** - Check if the input element is valid\n- **reportValidity(): _boolean_** - Report the validity of the input element\n- **addEventListener(type: _K_, listener: _(ev: InputEventMap[K]) => void_, options: _boolean | AddEventListenerOptions_): _void_** - Type safe event dispatcher - allows consumers to use proper types\nwhen listening to events from this component\n- **removeEventListener(type: _K_, listener: _(ev: InputEventMap[K]) => void_, options: _boolean | EventListenerOptions_): _void_** - Type safe event dispatcher removal\n\n### **CSS Parts:**\n - **input** - The native input element",
163
+ "description": "A fully type-safe input component that wraps the native HTML input element\nwhile providing additional functionality and styling.\n---\n\n\n### **Events:**\n - **input** - Fired when the input value changes\n- **change** - Fired when the input value is committed\n- **focus** - Fired when the input receives focus\n- **blur** - Fired when the input loses focus\n- **invalid** - Fired when the input fails validation\n\n### **Methods:**\n - **focus(options: _FocusOptions_): _void_** - Focus the input element\n- **blur(): _void_** - Remove focus from the input element\n- **select(): _void_** - Select all text in the input element\n- **setSelectionRange(start: _number_, end: _number_, direction: _'forward' | 'backward' | 'none'_): _void_** - Set the selection range of the input element\n- **checkValidity(): _boolean_** - Check if the input element is valid\n- **reportValidity(): _boolean_** - Report the validity of the input element\n- **addEventListener(type: _K_, listener: _(ev: InputEventMap[K]) => void_, options: _boolean | AddEventListenerOptions_): _void_** - Type safe event dispatcher - allows consumers to use proper types\nwhen listening to events from this component\n- **removeEventListener(type: _K_, listener: _(ev: InputEventMap[K]) => void_, options: _boolean | EventListenerOptions_): _void_** - Type safe event dispatcher removal\n\n### **CSS Parts:**\n - **input** - The native input element",
158
164
  "attributes": [
159
165
  { "name": "value", "values": [] },
160
166
  { "name": "placeholder", "values": [] },
@@ -169,8 +175,7 @@
169
175
  { "name": "min", "values": [] },
170
176
  { "name": "max", "values": [] },
171
177
  { "name": "step", "values": [] },
172
- { "name": "autocomplete", "values": [] },
173
- { "name": "id", "values": [] }
178
+ { "name": "autocomplete", "values": [] }
174
179
  ],
175
180
  "references": []
176
181
  },
@@ -210,7 +215,7 @@
210
215
  },
211
216
  {
212
217
  "name": "primer-input-wrapper",
213
- "description": "A wrapper component for input elements that handles focus styling and interactions.\nProvides an improved user experience by making the entire wrapper clickable to focus the inner input.\n\nFeatures:\n- Automatically focuses primer-input elements when wrapper is clicked\n- Dispatches wrapper-click events for iframe-based hosted inputs\n- Sets proper cursor styling to indicate text input functionality\n---\n\n\n### **Events:**\n - **wrapper-click**",
218
+ "description": "A wrapper component for input elements that handles focus styling and interactions.\nProvides an improved user experience by making the entire wrapper clickable to focus the inner input.\n\nFeatures:\n- Automatically focuses primer-input elements when wrapper is clicked\n- Dispatches wrapper-click events for iframe-based hosted inputs\n- Sets proper cursor styling to indicate text input functionality\n---\n",
214
219
  "attributes": [
215
220
  { "name": "focusWithin", "values": [] },
216
221
  { "name": "has-error", "values": [] }
@@ -261,6 +266,7 @@
261
266
  "description": "CardFormComponent serves as a container for card input components.\nIt handles form submission, validation, and provides context to child components.\n---\n",
262
267
  "attributes": [
263
268
  { "name": "hide-labels", "values": [] },
269
+ { "name": "disabled", "values": [] },
264
270
  {
265
271
  "name": "paymentManagers",
266
272
  "description": "Payment managers injected from context",
@@ -294,15 +300,16 @@
294
300
  "name": "paymentManagers",
295
301
  "values": [{ "name": "InitializedManagersMap" }]
296
302
  },
297
- { "name": "sdkState", "values": [{ "name": "SdkStateContext" }] },
303
+ { "name": "sdkState", "values": [{ "name": "SdkStateContextType" }] },
298
304
  {
299
305
  "name": "headlessUtils",
300
- "values": [{ "name": "HeadlessUnitilsContext" }]
306
+ "values": [{ "name": "HeadlessUnitilsContextType" }]
301
307
  },
302
308
  {
303
309
  "name": "klarnaCategories",
304
- "values": [{ "name": "KlarnaCategoriesContext" }]
305
- }
310
+ "values": [{ "name": "KlarnaCategoriesContextType" }]
311
+ },
312
+ { "name": "disabled", "values": [] }
306
313
  ],
307
314
  "references": []
308
315
  },
@@ -321,7 +328,8 @@
321
328
  {
322
329
  "name": "computedStyles",
323
330
  "values": [{ "name": "CSSStyleDeclaration" }]
324
- }
331
+ },
332
+ { "name": "disabled", "values": [] }
325
333
  ],
326
334
  "references": []
327
335
  },
@@ -330,9 +338,10 @@
330
338
  "description": "\n---\n",
331
339
  "attributes": [
332
340
  { "name": "type", "values": [{ "name": "PaymentMethodType" }] },
341
+ { "name": "disabled", "values": [] },
333
342
  {
334
343
  "name": "paymentMethods",
335
- "values": [{ "name": "PaymentMethodsContext" }]
344
+ "values": [{ "name": "PaymentMethodsContextType" }]
336
345
  }
337
346
  ],
338
347
  "references": []
@@ -347,7 +356,7 @@
347
356
  "name": "primer-checkout-error",
348
357
  "description": "\n---\n",
349
358
  "attributes": [
350
- { "name": "sdkState", "values": [{ "name": "SdkStateContext" }] }
359
+ { "name": "sdkState", "values": [{ "name": "SdkStateContextType" }] }
351
360
  ],
352
361
  "references": []
353
362
  },
@@ -357,9 +366,13 @@
357
366
  "attributes": [
358
367
  {
359
368
  "name": "paymentMethods",
360
- "values": [{ "name": "PaymentMethodsContext" }]
369
+ "values": [{ "name": "PaymentMethodsContextType" }]
361
370
  },
362
- { "name": "sdkState", "values": [{ "name": "SdkStateContext" }] }
371
+ { "name": "sdkState", "values": [{ "name": "SdkStateContextType" }] },
372
+ {
373
+ "name": "clientOptions",
374
+ "values": [{ "name": "ClientOptionsContextType" }]
375
+ }
363
376
  ],
364
377
  "references": []
365
378
  },
@@ -370,7 +383,8 @@
370
383
  {
371
384
  "name": "paymentMethod",
372
385
  "values": [{ "name": "InitializedPaymentMethod" }]
373
- }
386
+ },
387
+ { "name": "disabled", "values": [] }
374
388
  ],
375
389
  "references": []
376
390
  },
@@ -403,13 +417,17 @@
403
417
  },
404
418
  {
405
419
  "name": "headlessInstance",
406
- "values": [{ "name": "HeadlessUnitilsContext" }]
420
+ "values": [{ "name": "HeadlessUnitilsContextType" }]
407
421
  },
408
422
  {
409
423
  "name": "clientOptions",
410
- "values": [{ "name": "ClientOptionsContext" }]
424
+ "values": [{ "name": "ClientOptionsContextType" }]
425
+ },
426
+ { "name": "sdkState", "values": [{ "name": "SdkStateContextType" }] },
427
+ {
428
+ "name": "cardFormContext",
429
+ "values": [{ "name": "CardFormContext" }]
411
430
  },
412
- { "name": "sdkState", "values": [{ "name": "SdkStateContext" }] },
413
431
  {
414
432
  "name": "variant",
415
433
  "description": "The button variant to use.",
@@ -533,6 +551,12 @@
533
551
  ],
534
552
  "references": []
535
553
  },
554
+ {
555
+ "name": "primer-payment-method-content",
556
+ "description": "PaymentMethodContentComponent - renders payment method information with icon and details\nThis component encapsulates the display logic and styles for payment method content\nso it can be reused across different containers without style conflicts\n---\n",
557
+ "attributes": [],
558
+ "references": []
559
+ },
536
560
  {
537
561
  "name": "primer-vault-cvv-input",
538
562
  "description": "CVV Input component for vault payment methods\nRenders a secure iframe for CVV input when required by the selected payment method\nUses dedicated CVV context to minimize re-renders\n---\n\n\n### **Methods:**\n - **onCvvInputChange()** - Update CVV metadata in the context when input changes",
@@ -550,7 +574,7 @@
550
574
  },
551
575
  {
552
576
  "name": "primer-vault-delete-confirmation",
553
- "description": "VaultDeleteConfirmationComponent - displays confirmation UI for deleting a payment method\n---\n\n\n### **Events:**\n - **confirm-delete**\n- **cancel-delete**",
577
+ "description": "VaultDeleteConfirmationComponent - displays confirmation UI for deleting a payment method\n---\n",
554
578
  "attributes": [
555
579
  {
556
580
  "name": "isDeleting",
@@ -578,7 +602,7 @@
578
602
  },
579
603
  {
580
604
  "name": "primer-vault-error-message",
581
- "description": "VaultErrorMessageComponent - displays error messages with improved visuals\n---\n\n\n### **Events:**\n - **close-error**",
605
+ "description": "VaultErrorMessageComponent - displays error messages with improved visuals\n---\n",
582
606
  "attributes": [
583
607
  {
584
608
  "name": "errorMessage",
@@ -590,7 +614,7 @@
590
614
  },
591
615
  {
592
616
  "name": "primer-vault-manager-header",
593
- "description": "VaultManagerHeaderComponent - displays the header for the vault manager\n---\n\n\n### **Events:**\n - **toggle-edit-mode**",
617
+ "description": "VaultManagerHeaderComponent - displays the header for the vault manager\n---\n",
594
618
  "attributes": [
595
619
  {
596
620
  "name": "isEditMode",
@@ -607,11 +631,11 @@
607
631
  },
608
632
  {
609
633
  "name": "primer-vault-payment-method-item",
610
- "description": "VaultPaymentMethodItemComponent - displays a single payment method\nUses the VaultManagerController for display formatting\nNow supports selection via the simplified button checked state\nEnhanced with smooth transitions between edit and payment modes\nAlways renders the primer-button for consistent UI and improved accessibility\n---\n\n\n### **Events:**\n - **delete-payment-method**",
634
+ "description": "VaultPaymentMethodItemComponent - displays a single payment method\nUses the VaultManagerController for display formatting\nNow supports selection via the simplified button checked state\nEnhanced with smooth transitions between edit and payment modes\nAlways renders the primer-button for consistent UI and improved accessibility\n---\n",
611
635
  "attributes": [
612
636
  {
613
637
  "name": "headlessUtils",
614
- "values": [{ "name": "HeadlessUnitilsContext" }]
638
+ "values": [{ "name": "HeadlessUnitilsContextType" }]
615
639
  },
616
640
  {
617
641
  "name": "isEditMode",
@@ -632,9 +656,9 @@
632
656
  },
633
657
  {
634
658
  "name": "headlessInstance",
635
- "values": [{ "name": "HeadlessUnitilsContext" }]
659
+ "values": [{ "name": "HeadlessUnitilsContextType" }]
636
660
  },
637
- { "name": "sdkState", "values": [{ "name": "SdkStateContext" }] },
661
+ { "name": "sdkState", "values": [{ "name": "SdkStateContextType" }] },
638
662
  {
639
663
  "name": "variant",
640
664
  "description": "The button variant to use.",