trendyol / baklava-react-native Goto Github PK
View Code? Open in Web Editor NEWHome Page: https://trendyol.github.io/baklava-react-native/
License: MIT License
Home Page: https://trendyol.github.io/baklava-react-native/
License: MIT License
General usage example:
<Image bordered={false} width={200} height={200} />
bordered
to keep the contrast between the image that placed and the background.Image
componentAn image is a graphic representation of something or someone.
Property | Description | Default Value |
---|---|---|
bordered (boolean ) |
gray border of image | true |
width (number ) |
image width | 48 |
height (number ) |
image height | 72 |
There is no proper working rating component especially in react native. I had to write my own and use it in my projects and production. It would be great to have one in baklava
Describe the solution you'd like
General usage example:
const [isPressed, setIsPressed] = useState(false)
// ...
<TextLink
variant="subtitle3Medium"
onPress={() => setIsPressed(true)}
isPressed={isPressed}
>
Example
</TextLink>
Put some rules about how this component should behave and implemented
TextLink
componentText link is a navigational element that takes a user to another URL, an element within a page, or a file.
Property | Description | Default Value |
---|---|---|
variant (string ) |
The variant of the Text style to use | body2 |
isPressed (boolean ) |
The pressed state of the TextLink | false |
onPress (function ) |
The onPress function of the TextLink | - |
General usage example:
<TextArea label="Lorem" placeHolder="Lorem" size="small" maxLength={200} />
TextArea
componentText areas let users enter and edit text.
Property | Description | Default Value |
---|---|---|
label (string ) |
content string | - |
labelFixed (boolean ) |
inline label type | false |
placeHolder (string ) |
The string that will be rendered before text input has been entered. | - |
disabled (boolean ) |
disable state of textArea | false |
helpText (string ) |
Helper text providing information for the input. | - |
counterText (string ) |
Counts the length of the textArea | - |
error (boolean ) |
Boolean value indicating the error status. | false |
errorText (string ) |
Helper text showing the error in the input. | - |
maxLength (number ) |
max length of content | 200 |
maxLengthErrorText (string ) |
Helper text showing the error if exceed maxLength | - |
size (large | medium | small ) |
size of TextArea | medium |
General usage example:
const [value, setValue] = useState("tab1");
//...
<Tabs value={value} onValueChange={setValue}>
<Tabs.List>
<Tabs.Option value="tab1" title="tab 1" caption="" badge={<Badge variant="" />} icon="" disabled>
<Tabs.Option value="tab2" title="tab 2" caption="" badge={<Badge variant="" />} icon="">
</Tabs.List>
<Tabs.Content value="tab1"><ContentView /></Tabs.Content>
<Tabs.Content value="tab2"><ContentView /></Tabs.Content>
</Tabs>
Tabs
componentTabs are used to organize related content. They allow the user to navigate between groups of information that appear within the same context.
Property | Description | Default Value |
---|---|---|
value (string ) |
The value of the Tab | - |
onValueChange (function ) |
The onValueChange function of the Tab | - |
defaultValue (string ) |
The defaultValue of the Tab | - |
Property | Description | Default Value |
---|---|---|
value (string ) |
The value of the Tab | - |
title (string ) |
The title of the Tab | - |
caption (string ) |
The caption of the Tab | - |
icon (string ) |
The icon of the Tab | - |
badge (Badge ) |
The badge of the Tab | - |
disabled (boolean ) |
The disabled state of the Tab | false |
visible (boolean ) |
The visible state of the Tab | true |
General usage example:
<Component>Example</Component>
Put some rules about how this component should behave and implemented
Component
componentDescription
Property | Description | Default Value |
---|---|---|
attr (string ) |
attr desc | - |
Figma Design Document
General usage example:
<Component>Example</Component>
Put some rules about how this component should behave and implemented
Component
componentDescription
Property | Description | Default Value |
---|---|---|
attr (string ) |
attr desc | - |
Figma Design Document
General usage example:
<Component>Example</Component>
Put some rules about how this component should behave and implemented
Component
componentDescription
Property | Description | Default Value |
---|---|---|
attr (string ) |
attr desc | - |
General usage example:
<Component>Example</Component>
Put some rules about how this component should behave and implemented
Component
componentDescription
Property | Description | Default Value |
---|---|---|
attr (string ) |
attr desc | - |
Describe the bug
Badge texts are bold on ios but not on android.
Describe the bug
The optional text in the input component should be changeable.
To Reproduce
Steps to reproduce the behavior:
Smartphone:
We decided to drop styled-components and styled-system packages and switch to the @shopify/restyle package as the core styling mechanism.
PR: #28
General usage example:
<Input size="large" placeholder="Large" />
Input
componentThe Input component allows a user to provide input in a text field.
Property | Description | Default Value |
---|---|---|
size (string ) |
The size of the button | medium |
label (string ) |
The text or component to use for the floating label | - |
labelFixed (boolean ) |
Boolean value that checks if the label is fixed. | false |
placeholder (string ) |
The string that will be rendered before text input has been entered. | - |
helpText (string ) |
Helper text providing information for the input. | - |
errorText (string ) |
Helper text showing the error in the input. | - |
successText (string ) |
Helper text showing the success in the input. | - |
icon (string ) |
The icon shown in the input. | - |
success (Boolean ) |
Boolean value indicating the success status. | false |
error (boolean ) |
Boolean value indicating the error status. | false |
secureTextEntry (boolean ) |
If true, the text input obscures the text entered so that sensitive text like passwords stay secure. The default value is false. | false |
required (Boolean ) |
Boolean value that controls whether the field is required. | false |
disabled (boolean ) |
If true, user won't be able to interact with the component. | false |
style (StyleProp<TextInputStyle> ) |
attr desc | - |
Figma Design Document
General usage example:
<Component>Example</Component>
Put some rules about how this component should behave and implemented
Component
componentDescription
Property | Description | Default Value |
---|---|---|
attr (string ) |
attr desc | - |
Is your feature request related to a problem? Please describe.
The Sizes page contains sizes, font sizes, font weights, and border-radius.
Describe the solution you'd like
These tokens should move to separate pages.
Figma Design Document
General usage example:
<Component>Example</Component>
Put some rules about how this component should behave and implemented
Component
componentDescription
Property | Description | Default Value |
---|---|---|
attr (string ) |
attr desc | - |
<Badge variant="success" text="Lorem Ipsum" />
Badge
componentBadge component can be used for highlighting a status or labeling an item.
Property | Description | Default Value |
---|---|---|
variant (string ) |
The variant of the badge style to use | default |
icon (string ) |
The icon shown in the badge | - |
size (string ) |
The size of the badge | medium |
transparent (boolean ) |
Use key colors on the content without background | false |
General usage example:
<Tooltip visible={true} >
<Icon/>
</Tooltip>
Tooltip
componentTooltips display informative text when users hover over, focus on, or tap an element.
Property | Description | Default Value |
---|---|---|
visible (boolean ) |
state of visibility | false |
onClose (function ) |
close callback | - |
content (string ) |
message of tooltip content | - |
Describe the bug
Some props of Button are not included in the document. eg filled. Can it be checked and updated?
General usage example:
<Text variant="heading2">Baklava Design System</Text>
Available variants:
Heading: heading1
, heading2
, heading3
Subtitle01: subtitle01Regular
, subtitle01Medium
, subtitle01Semibold
, subtitle01Bold
Subtitle02: subtitle02Regular
, subtitle02Medium
, subtitle02Semibold
, subtitle02Bold
Subtitle03: subtitle03Regular
, subtitle03Medium
, subtitle03Semibold
, subtitle03Bold
Subtitle04: subtitle04Regular
, subtitle04Medium
, subtitle04Semibold
, subtitle04Bold
Body: bodyText
, bodyUnderline
, bodyTextLink
, bodyLongText
Caption: captionText
, captionMedium
, captionLongText
, captionTextLink
Text
componentTypography creates purposeful texture, guiding users to read and understand the hierarchy of information.
Property | Description | Default Value |
---|---|---|
variant (string ) |
Variant defines appropriate text styles for type role and its size | bodyText |
children (required) (string ) |
- | - |
style (StyleProp<TextStyle> ) |
StyleProp | - |
main
branch failed. 🚨I recommend you give this issue a high priority, so other packages depending on you can benefit from your bug fixes and new features again.
You can find below the list of errors reported by semantic-release. Each one of them has to be resolved in order to automatically publish your package. I’m sure you can fix this 💪.
Errors are usually caused by a misconfiguration or an authentication problem. With each error reported below you will find explanation and guidance to help you to resolve it.
Once all the errors are resolved, semantic-release will release your package the next time you push a commit to the main
branch. You can also manually restart the failed CI job that runs semantic-release.
If you are not sure how to resolve this, here are some links that can help you:
If those don’t help, or if this issue is reporting something you think isn’t right, you can always ask the humans behind semantic-release.
An npm token must be created and set in the NPM_TOKEN
environment variable on your CI environment.
Please make sure to create an npm token and to set it in the NPM_TOKEN
environment variable on your CI environment. The token must allow to publish to the registry https://registry.npmjs.org/
.
Good luck with your project ✨
Your semantic-release bot 📦🚀
General usage example:
<Box>
<Text>This is a Box</Text>
</Box>
Box
componentThis is a generic component for low level layout needs. It is similar to a div in HTML and View in React Native.
Box implements View, flexbox, color, size, space, borders, borderRadius props
General usage example:
<Button variant="primary" type="outline" size="large" label="Primary Button" />
Button
componentA button is component that the user can press to trigger an action.
Property | Description | Default Value |
---|---|---|
variant (string ) |
The variant of the button style to use | primary |
type (string ) |
The type of the button. To adjust the styling to give it desired emphasis | contained |
size (string ) |
The size of the button | medium |
style (StyleProp<PressableStyle> ) |
StyleProp | - |
General usage example:
<Component>Example</Component>
Put some rules about how this component should behave and implemented
Component
componentDescription
Property | Description | Default Value |
---|---|---|
attr (string ) |
attr desc | - |
It seems there is no exports for the TextLink components.
Please see: https://github.com/Trendyol/baklava-react-native/blob/main/src/index.ts
We added the mobile button sizes to design guide.
General usage example:
const [value, setValue] = useState(false);
const toggleValue = () => setValue(!value);
// ...
<Switch value={value} onValueChange={toggleValue} label="Label" />
Switch
componentSwitches toggle the state of a single item on or off.
Property | Description | Default Value |
---|---|---|
label (string ) |
The label of the switch | - |
value (boolean ) |
The value of the switch | false |
onValueChange (function ) |
Callback called with the new value when it changes. | - |
disabled (boolean ) |
The disabled state of the switch | false |
onColor (Theme['colors'] | string ) |
The on color of the switch | "primaryKey" |
offColor (Theme['colors'] | string ) |
The off color of the switch | "neutralLighter" |
testID (string ) |
The testID of the switch | "switch-component" |
Describe the bug
The switch component does not update when its value changes programmatically. Also, setting the initial value seems does not work.
To Reproduce
Use the switch component with the initial value and change the value from somewhere.
const [value, setValue] = React.useState(true)
return (
<>
<Switch
value={value}
onColor="#0BC15C"
offColor="#FF5043"
onValueChange={(value) => {
setValue(value)
}}
/>
<Button label="Make it false" onPress={() => setValue(false)} />
</>
)
General usage example:
<Icon name="confetti" color="primaryColor" size="xlarge" />
Icon
componentIcon component is used to show some decorative icons.
Property | Description | Default Value |
---|---|---|
name (string ) |
Icon names are in the list, fixed and cannot be used outside the list | contentPrimary |
size (string ) |
The size of the icon | large |
style (StyleProp<PressableStyle> ) |
StyleProp | - |
General usage example:
<Modal
title="Title"
closeButtonAction = { () => {} }
actionButtonProps={{ onPress: () => {}, label: "text"}}
secondActionButtonProps={{ onPress: () => {}, label: "text"}}
>
<Box/>
</Modal>
Modal
componentModals inform users about a task and can contain critical information, require decisions, or involve multiple tasks.
Property | Description | Default Value |
---|---|---|
title (string ) |
title of modal | - |
closeButtonAction (function ) |
close button action of modal | - |
children (React.Component ) |
free area of modal | - |
actionButtonProps (ButtonProps ) |
first buttons' actions | - |
secondActionButtonProps (ButtonProps ) |
second buttons' actions | - |
General usage example:
<Checkbox disable={false} checked={true} indeterminate={true} label="lorem ipsum" />
Checkbox
componentCheckboxes allow users to select one or more items from a set.
Property | Description | Default Value |
---|---|---|
checked (boolean ) |
state of selected | false |
indeterminate (boolean ) |
state of indeterminate | false |
label (string ) |
label for checkbox | - |
disabled (boolean ) |
state of disabled | false |
main
branch failed. 🚨I recommend you give this issue a high priority, so other packages depending on you can benefit from your bug fixes and new features again.
You can find below the list of errors reported by semantic-release. Each one of them has to be resolved in order to automatically publish your package. I’m sure you can fix this 💪.
Errors are usually caused by a misconfiguration or an authentication problem. With each error reported below you will find explanation and guidance to help you to resolve it.
Once all the errors are resolved, semantic-release will release your package the next time you push a commit to the main
branch. You can also manually restart the failed CI job that runs semantic-release.
If you are not sure how to resolve this, here are some links that can help you:
If those don’t help, or if this issue is reporting something you think isn’t right, you can always ask the humans behind semantic-release.
An npm token must be created and set in the NPM_TOKEN
environment variable on your CI environment.
Please make sure to create an npm token and to set it in the NPM_TOKEN
environment variable on your CI environment. The token must allow to publish to the registry https://registry.npmjs.org/
.
Good luck with your project ✨
Your semantic-release bot 📦🚀
General usage example:
<Spinner color="primaryKey" size="m" />
Spinner
componentLoading spinners are used when retrieving data or performing slow computations and help to notify users that loading is underway.
Property | Description | Default Value |
---|---|---|
color (ThemeColor or ColorValue ) |
spinner main color | primaryKey |
size (string ) |
spinner size | m |
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.