Skip to content

Conversation

JYSW380
Copy link
Contributor

@JYSW380 JYSW380 commented Jun 26, 2019

Closes #127

This PR contains the self-contained styling for the spinner component.
This PR is part of the larger task of making all components self-contained. #136

@JYSW380 JYSW380 requested a review from greg-a-smith June 26, 2019 17:24
@netlify
Copy link

netlify bot commented Jun 26, 2019

Deploy preview for fundamental-styles ready!

Built with commit 6d3b361

https://deploy-preview-130--fundamental-styles.netlify.com

@JYSW380 JYSW380 changed the title fixed spinner self container component fix: added self container styles for spinner component Jun 27, 2019
Copy link
Contributor

@jbadan jbadan left a comment

Choose a reason for hiding this comment

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

Looks like we're missing a variable in the ugly theme - --fd-color-background-1

Separately, should we be using aria-* as selectors in the scss? That might be separate followup story to rewrite those.

@@ -0,0 +1,4 @@
$fd-fonts-path: "../scss/fonts/";
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't think this component needs fonts to work

Copy link
Contributor Author

Choose a reason for hiding this comment

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

no, we dont need fonts, thanks for point out.

Copy link
Contributor

@greg-a-smith greg-a-smith left a comment

Choose a reason for hiding this comment

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

@jbadan is correct. We should NOT be using aria-* attributes as CSS selectors. I know it's not technically part of making this self-contained styles, but this is a good time to clean some of that up.

Also, there is an unclassed div element selector in the scss/components/spinner.scss file. Although this div element selector is a child of .fd-spinner, this should be changed to use a class selector to avoid anything bleeding in or out.

@greg-a-smith greg-a-smith changed the title fix: added self container styles for spinner component fix: added self-contained styles for spinner component Jun 28, 2019

{% set example %}
<div class="fd-panel" aria-busy="true">
<div class="fd-panel is-busy">
Copy link
Contributor

Choose a reason for hiding this comment

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

The "hidden" example should be redone as it no longer is triggered by aria-hidden. The text should be changed and the example itself should implement the is-hidden class.

Copy link
Contributor

@greg-a-smith greg-a-smith left a comment

Choose a reason for hiding this comment

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

Looks good. 🚢 (assuming the build passes)

Copy link
Contributor

@greg-a-smith greg-a-smith left a comment

Choose a reason for hiding this comment

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

Sorry, I missed @jbadan's review comment. Added the missing variable to theme-ugly.css. Looks good though. 🚢

--fd-color-background-3: rgb(47%, 36%, 91%);
--fd-color-background-4: rgb(51%, 6%, 2%);
--fd-color-alert: rgb(84%, 13%, 91%);
--fd-color-background-5: rgb(13%, 71%, 90%);
Copy link
Contributor

Choose a reason for hiding this comment

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

Really just reorganized/reordered these. The only addition was --fd-color-background-1.

@saad-mo
Copy link
Contributor

saad-mo commented Jul 15, 2019

this component (fd-spinner) is deprecated in favor of fd-loading-spinner and fd-loading-dots - https://sap.github.io/fundamental/components/loading-spinner.html

this should be removed from the styles lib and we should work on the new ones instead.

@greg-a-smith @jbadan @droshev thought?

@greg-a-smith
Copy link
Contributor

@saad-mo If this component is deprecated, I agree we should begin work on its replacements. That said, until those replacements exist, this needs to stay so we should push this PR through and create a GitHub issue to have it removed once the replacement components are available.

@JYSW380 JYSW380 merged commit 28ce75c into master Jul 15, 2019
@JYSW380 JYSW380 deleted the fix/129-self-contained-styles-for-spinner-component branch July 15, 2019 17:32
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.

5 participants