Skip to content

Commit

Permalink
[open-formulieren/open-forms#5006] Updated addressNL component schema…
Browse files Browse the repository at this point in the history
… and preview in the builder according to autoPopulated field
  • Loading branch information
vaszig committed Jan 16, 2025
1 parent 10c1985 commit eb58870
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/components/ComponentConfiguration.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2360,6 +2360,7 @@ export const AddressNL: Story = {
required: false,
},
deriveAddress: false,
autoPopulated: false,
layout: 'singleColumn',
openForms: {
components: {
Expand Down
1 change: 1 addition & 0 deletions src/components/ComponentPreview.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1055,6 +1055,7 @@ export const AddressNL: Story = {
},
deriveAddress: false,
layout: 'singleColumn',
autoPopulated: false,
},
},
};
Expand Down
1 change: 1 addition & 0 deletions src/registry/addressNL/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,6 @@ export default {
city: '',
streetName: '',
secretStreetCity: '',
autoPopulated: false,
},
} satisfies RegistryEntry<AddressNLComponentSchema>;
2 changes: 2 additions & 0 deletions src/registry/addressNL/preview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ const Preview: React.FC<ComponentPreviewProps<AddressNLComponentSchema>> = ({com
/>
}
disabled
required={required}
/>
<TextField
name={`${key}.streetNumber`}
Expand All @@ -80,6 +81,7 @@ const Preview: React.FC<ComponentPreviewProps<AddressNLComponentSchema>> = ({com
/>
}
disabled
required={required}
/>
</>
)}
Expand Down

0 comments on commit eb58870

Please sign in to comment.