From 6b1a3c9169ccb05037decda7634dbe24d788cdf8 Mon Sep 17 00:00:00 2001 From: Ankit Kumar Date: Sun, 26 Apr 2020 04:37:52 +0530 Subject: [PATCH] Added fullWidth prop to multiple components --- packages/docs/src/pages/components/card.js | 70 ++++++++++++++++++- packages/docs/src/pages/components/input.js | 17 +++++ packages/docs/src/pages/components/select.js | 27 +++++++ .../docs/src/pages/components/textarea.js | 17 +++++ .../react-ui/src/components/card/index.js | 12 +++- .../react-ui/src/components/input/index.js | 7 +- .../react-ui/src/components/select/index.js | 10 ++- .../react-ui/src/components/textarea/index.js | 7 +- 8 files changed, 157 insertions(+), 10 deletions(-) diff --git a/packages/docs/src/pages/components/card.js b/packages/docs/src/pages/components/card.js index d47cdcb..78334d5 100644 --- a/packages/docs/src/pages/components/card.js +++ b/packages/docs/src/pages/components/card.js @@ -1,6 +1,6 @@ import React from 'react' import { ThemeProvider, Card, Stack, Link, Text } from 'react-ui' -import { Page, Example, Section, Table, Para } from '../../components' +import { Page, Props, Example, Section, Table, Para } from '../../components' const Documentation = () => { return ( @@ -16,6 +16,19 @@ const Documentation = () => { +
+ +
+
@@ -71,6 +84,61 @@ const Documentation = () => { `} + + + + + + + + 09:15 + + AMS + + + + 8h 35 + Direct + + + 11:50 + + JFK + + + + + + + {` + + + + + + 09:15 + AMS + + + + 8h 35 + Direct + + + + 11:50 + JFK + + + + + + `} +
diff --git a/packages/docs/src/pages/components/input.js b/packages/docs/src/pages/components/input.js index 9b17df5..fef3325 100644 --- a/packages/docs/src/pages/components/input.js +++ b/packages/docs/src/pages/components/input.js @@ -28,6 +28,12 @@ const Documentation = () => { description: 'type of avatar, example: text, password, number, etc.', default: 'text' + }, + { + name: 'fullWidth', + type: 'boolean', + description: 'Make input take 100% width of the container', + default: 'false' } ]} /> @@ -54,6 +60,17 @@ const Documentation = () => { `} + + + + + + + {` + + `} + +
diff --git a/packages/docs/src/pages/components/select.js b/packages/docs/src/pages/components/select.js index e23d6bc..c816104 100644 --- a/packages/docs/src/pages/components/select.js +++ b/packages/docs/src/pages/components/select.js @@ -36,6 +36,12 @@ const Documentation = () => { name: '+', type: 'props of Input', description: '' + }, + { + name: 'fullWidth', + type: 'boolean', + description: 'Make select take 100% width of the container', + default: 'false' } ]} /> @@ -88,6 +94,27 @@ const Documentation = () => { `} + + + + + + + {` + + `} + +
diff --git a/packages/docs/src/pages/components/textarea.js b/packages/docs/src/pages/components/textarea.js index 631af97..b1344a5 100644 --- a/packages/docs/src/pages/components/textarea.js +++ b/packages/docs/src/pages/components/textarea.js @@ -34,6 +34,12 @@ const Documentation = () => { name: '+', type: 'props of Input', description: '' + }, + { + name: 'fullWidth', + type: 'boolean', + description: 'Make textarea take 100% width of the container', + default: 'false' } ]} /> @@ -58,6 +64,17 @@ const Documentation = () => {