goobs-frontend 0.122.2 → 0.122.3

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "goobs-frontend",
3
- "version": "0.122.2",
3
+ "version": "0.122.3",
4
4
  "type": "module",
5
5
  "description": "A comprehensive React-based libary for building modern web applications",
6
6
  "license": "MIT",
@@ -24,6 +24,7 @@ import VLANField from '../../../Field/IPAM/VLAN'
24
24
  import CIDRField from '../../../Field/IPAM/CIDR'
25
25
  import SupernetField from '../../../Field/IPAM/Supernet'
26
26
  import MACAddressField from '../../../Field/IPAM/MACAddress'
27
+ import USDField from '../../../Field/USD'
27
28
 
28
29
  interface CreationRowProps {
29
30
  columns: ColumnDef[]
@@ -71,6 +72,24 @@ const CreationRow: React.FC<CreationRowProps> = ({
71
72
  }
72
73
 
73
74
  switch (fieldConfig.type) {
75
+ case 'currency':
76
+ case 'usd': {
77
+ return (
78
+ <USDField
79
+ initialValue={String(value ?? '')}
80
+ onChange={(newValue: string) =>
81
+ onCreationFieldChange?.(column.field, newValue)
82
+ }
83
+ {...(fieldConfig.placeholder
84
+ ? { placeholder: fieldConfig.placeholder }
85
+ : {})}
86
+ {...(fieldConfig.helperText
87
+ ? { helperText: fieldConfig.helperText }
88
+ : {})}
89
+ styles={fieldStyles}
90
+ />
91
+ )
92
+ }
74
93
  case 'text':
75
94
  return (
76
95
  <TextField
@@ -57,6 +57,8 @@ export interface ColumnDef {
57
57
  type:
58
58
  | 'text'
59
59
  | 'date'
60
+ | 'currency'
61
+ | 'usd'
60
62
  | 'dropdown'
61
63
  | 'searchableDropdown'
62
64
  | 'multiselect'