Skip to content

Commit

Permalink
Merge branch 'main' into joshblack-patch-1
Browse files Browse the repository at this point in the history
  • Loading branch information
kodiakhq[bot] authored Jun 14, 2022
2 parents afd57d2 + 88d7121 commit 1a85612
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 18 deletions.
3 changes: 3 additions & 0 deletions packages/react/__tests__/__snapshots__/PublicAPI-test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -2157,6 +2157,9 @@ Map {
"className": Object {
"type": "string",
},
"closeOnSelect": Object {
"type": "bool",
},
"dateFormat": Object {
"type": "string",
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@
/* eslint-disable no-console */

import React from 'react';
import { action } from '@storybook/addon-actions';
import { withKnobs, boolean } from '@storybook/addon-knobs';
import { Breadcrumb, BreadcrumbItem, BreadcrumbSkeleton } from '../Breadcrumb';
import OverflowMenu from '../OverflowMenu';
import OverflowMenuItem from '../OverflowMenuItem';
Expand All @@ -22,7 +20,6 @@ export default {
BreadcrumbItem,
BreadcrumbSkeleton,
},
decorators: [withKnobs],
parameters: {
docs: {
page: mdx,
Expand Down Expand Up @@ -62,24 +59,21 @@ export const BreadcrumbWithOverflowMenu = () => (

export const Skeleton = () => <BreadcrumbSkeleton />;

const props = () => ({
className: 'some-class',
noTrailingSlash: boolean('No trailing slash (noTrailingSlash)', false),
onClick: action('onClick'),
});

export const Playground = () => (
<Breadcrumb {...props()}>
export const Playground = (args) => (
<Breadcrumb {...args}>
<BreadcrumbItem>
<a href="/#">Breadcrumb 1</a>
</BreadcrumbItem>
<BreadcrumbItem href="#">Breadcrumb 2</BreadcrumbItem>
<BreadcrumbItem
href="#"
{...props()}
isCurrentPage={boolean('Is current page (isCurrentPage)', false)}>
Breadcrumb 3
</BreadcrumbItem>
<BreadcrumbItem href="#">Breadcrumb 3</BreadcrumbItem>
<BreadcrumbItem>Breadcrumb 4</BreadcrumbItem>
</Breadcrumb>
);

Playground.argTypes = {
children: {
table: {
disable: true,
},
},
};
7 changes: 7 additions & 0 deletions packages/react/src/components/DatePicker/DatePicker.js
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,7 @@ function DatePicker({
appendTo,
children,
className,
closeOnSelect = true,
dateFormat = 'm/d/Y',
datePickerType,
disable,
Expand Down Expand Up @@ -286,6 +287,7 @@ function DatePicker({
inline: inline ?? false,
disableMobile: true,
defaultDate: value,
closeOnSelect: closeOnSelect,
mode: datePickerType,
allowInput: allowInput ?? true,
dateFormat: dateFormat,
Expand Down Expand Up @@ -488,6 +490,11 @@ DatePicker.propTypes = {
*/
className: PropTypes.string,

/**
* flatpickr prop passthrough. Controls whether the calendar dropdown closes upon selection.
*/
closeOnSelect: PropTypes.bool,

/**
* The date format.
*/
Expand Down
2 changes: 1 addition & 1 deletion packages/react/src/components/Grid/Grid.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ In these situations, you can make use of the auto columns feature of the
breakpoint props, and it will automatically set each column to a percentage of
the total available width.

For example, if you have on `Column` component it would span 100%, two `Column`
For example, if you have one `Column` component it would span 100%, two `Column`
components would span 50% each, four `Column` components would span 25% each,
and so on.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ const RadioButton = React.forwardRef(function RadioButton(
ref={ref}
disabled={disabled}
value={value}
name={name}
/>
<label htmlFor={uniqueId} className={`${prefix}--radio-button__label`}>
<span className={`${prefix}--radio-button__appearance`} />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,7 @@
@include type-style('body-compact-01');

display: flex;
flex-wrap: wrap;
word-break: break-word;
}

Expand Down

0 comments on commit 1a85612

Please sign in to comment.