From b77394ddca93ca495abcbc7d18b82733bd22d16a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ja=CC=81n=20Mikla=CC=81s=CC=8C?= Date: Mon, 18 May 2020 16:09:41 +0200 Subject: [PATCH] Add story with checkbox examples [MAILPOET-2773] --- .../form/checkbox/_stories/checkbox.tsx | 76 +++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 assets/js/src/common/form/checkbox/_stories/checkbox.tsx diff --git a/assets/js/src/common/form/checkbox/_stories/checkbox.tsx b/assets/js/src/common/form/checkbox/_stories/checkbox.tsx new file mode 100644 index 0000000000..b38ca0d1ba --- /dev/null +++ b/assets/js/src/common/form/checkbox/_stories/checkbox.tsx @@ -0,0 +1,76 @@ +import React from 'react'; +import { action } from '@storybook/addon-actions'; +import Checkbox from '../checkbox'; +import CheckboxGroup from '../group'; +import Heading from '../../../typography/heading/heading'; + +export default { + title: 'Form', + component: Checkbox, +}; + +const options = [ + { value: 1, label: 'Group option 1' }, + { value: 2, label: 'Group option 2' }, +]; + +export const Checkboxes = () => ( + <> + Inline individual checkboxes +
+ + Option 1 + + + Option 2 + +
+
+ + Full-width individual checkboxes +
+ + Option 1 + + + Option 2 + +
+
+ + Inline group checkboxes + +
+ + Full-width group checkboxes + + +);