Skip to content

Conversation

@jbadan
Copy link
Contributor

@jbadan jbadan commented Feb 28, 2020

Description

Modal

  • renamed Dialog
  • removed closeProps
  • actions now required
    Button
  • underlying class name changes
    ButtonGroup
  • classname changed to fd-segmented-button
  • Tab
    • remove disabled prop
    • change underlying html - added span around tab text
  • Shellbar
    • logo <a> is now <span>
    • added <div> around Identifier component
  • Alert
    • renamed MessageStrip
    • classname changes
    • removed Icon from underlying html
  • Dropdown
    • renamed Select
    • remove standard prop
  • ListGroup
    • renamed “List”
    • classname changes
    • so many changes! basically a new component!
  • MultiInput
    • underlying html changes
    • Popover body now built with List component
    • lots of underlying html changes for validation states
    • state prop replaced with validationState - takes object
    • localizedText prop removed
  • Combobox Input
    • underlying html changes
    • menu prop renamed list - now takes List component
    • state prop now validationState - takes an object
  • FormMessage
    • now a <div> from <span>
  • InputGroup
    • state prop now validationState - takes an object
    • underlying html changes to include FormMessage when passed validationState
  • SearchInput
  • Toggle
    • renamed to “Switch”
    • removed size options, now use compact property
    • labelProps no longer needed, additional props will be spread to the <label> element
    • underlying html changes - no longer wrapped in FormItem
  • Checkbox
    • new children prop
    • value prop changed
    • underlying html has changed significantly
  • FormRadioItem
    • underlying html has changed significantly
  • FormMessage
    • now an internal component
  • FormInput
    • removed state property
    • new validationState property
  • FormItem
    • remove isHorizontal prop
    • remove isInline prop (was internal only)
  • FormRadioGroup
    • now outputs <div> instead of Fragment
  • FormLabel
    • remove isCheckbox prop
    • remove isRadio prop
    • removed isToggle prop

See #888, #885 for a divided pr

Known Issues:
Toggle/Switch
- internalLabel prop not working in prop descriptions
- not an accessible pattern
- this is going to change ASAP as it is currently being redesigned
- icons are misaligned inside switch
Token:
- selected state - did not implement - what is this even used for?
Shellbar
- fd-shellbar__button needs more specificity
ListText
- —no-wrap class only works in selects - this should probably be part of select, not list
Select
- compact not working because —fd-forms-height-compact is not part of our postcss pipeline anymore - just SAP variables: SAP/fundamental-styles#711
MultiInput
- fd-tokenizer__input does not take priority over fd-input - getting the fd-input outline box (needs more specificity)
Validation states
- validation state styling - FS has the validation message as a list item instead of a div:SAP/fundamental-styles#712
- “onClickOutside” is not being handled correctly

webpack: true,
path: "lib/index.js",
limit: "180 KB"
limit: "200 KB"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's only 186 but I'm giving myself some headroom

@netlify
Copy link

netlify bot commented Feb 28, 2020

@netlify
Copy link

netlify bot commented Feb 28, 2020

@jbadan jbadan linked an issue Feb 28, 2020 that may be closed by this pull request
@jbadan jbadan requested a review from a team February 28, 2020 20:44
import { ComponentPage, Example } from '../_playground';
import React, { Component } from 'react';

export class DialogComponent extends Component {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could this be a functional component?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh this is copied from the previous ModalComponent - it just looks new from the name change. I don't really want to rework all the docs 😆

import React, { Component } from 'react';
class Modal extends Component {
// select body element to add Modal component too
class Dialog extends Component {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doesn't need to happen here, but this could be a functional component pretty easy too.

<MessageStrip {...createProps()}>Default MessageStrip</MessageStrip>
))
.add('Dismissable', () => (
<MessageStrip dismissable>MessageStrip</MessageStrip>
Copy link
Contributor

@skvale skvale Feb 28, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like it's spelled dismissible everywhere else. But dismissable does seem like the correct spelling...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh good catch - I can't spell 🤣

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dismissible is the correct spelling - I looked through the history and I've had to fix this a couple times because we(me) can't get it right. Maybe we change the prop name in the future 😆

// expect(wrapper.state(['isActive'])).toBeTruthy();

// wrapper.find('button.fd-message-strip__close').simulate('click');
// expect(wrapper.state(['isActive'])).toBeFalsy();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

?? Can we take these out now?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔥

@bcullman
Copy link
Contributor

bcullman commented Feb 29, 2020

a Herculean effort 💪 nice work! Just a few items:

modal looks like it is missing some padding:
image

TabGroup looks... not right.
image

validation state on multiinput cause field to shift around:
valstates

^ same issues in selects

popover placement in docs seems smushed:
image

@jbadan
Copy link
Contributor Author

jbadan commented Mar 2, 2020

@bcullman

  1. Dialog by default has no padding in the body 🤷‍♀ I added the additional sizes so that consumers can add padding as they wish. See https://fundamental-styles.netlify.com/components/dialog.html#dialog-size-modifiers
    I set the defaulted to large to prevent any confusion.

  2. TabGroup is updated with the new span class and I've now added the sizes now (defaulted to large like Dialog since the default from fundamental-styles has no padding). Other features see: Tabs: build out new functionality #891

  3. Popover & validation state jumping fixed on docs site - was a flexbox issue.

@jbadan jbadan requested a review from a team March 2, 2020 19:25
Copy link
Contributor

@skvale skvale left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!
The storyshots-test-js-storyshots-components-message-strip-dismissable-1-snap.png file could be deleted though

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

InputGroup: add focus states

4 participants