Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[settings.global] transition timing #214

Closed
fuhlig opened this issue Oct 24, 2016 · 6 comments
Closed

[settings.global] transition timing #214

fuhlig opened this issue Oct 24, 2016 · 6 comments

Comments

@fuhlig
Copy link

fuhlig commented Oct 24, 2016

The transition-duration in $global-transition (despite being in example files) should not be written as a division as the output will be:
transition: 0.33333333s; (depending on precision)

Suggestion: 0.3s or 300ms

The transition should also include a property and timing-function otherwise it uses the default all and linear

// simple
$global-transition: all 0.3s ease;

// 'advanced'
$global-transition-property: all;
$global-transition-duration: 0.3s;
$global-transition-timing-function: ease;

$global-transition: $global-transition-property $global-transition-duration $global-transition-timing-function;

.component {
  transition: $global-transition;
}

This might be out of scope for the inuit framework but just setting a duration could be a potential promotion of bad practice for transition.
It is open for discussion ofcourse and I'd be happy to open a Pull-Request when needed.

@herzinger
Copy link
Contributor

Seeing as it's only an example file, I don't see any problems here. You can do that in your own project if you want. There's no reason to make the exemple more complex.

@clindsey
Copy link

@fuhlig I think you have a good point about how the examples should be pragmatic since they're likely going to be used as a reference whether that was the intention or not.

@herzinger
Copy link
Contributor

Look, I agree that the best way to go about something like this is the way @fuhlig pointed out. To be more precise, his "advanced" exemple. Incidentally, it's the way I use it myself. But rather than introducing complexity in a exemple file, I would first consider removing the transition variable from it altogether.

@csshugs
Copy link
Member

csshugs commented Oct 25, 2016

Just because it's an example file, we still should not promote bad practice, so I'm with @fuhlig here (his simple example).

anselmh added a commit that referenced this issue Oct 25, 2016
@nenadjelovac
Copy link
Member

Just because it's an example file, we still should not promote bad practice, so I'm with @fuhlig here (his simple example).

Fully agreed with @csshugs and @fuhlig here.

@anselmh
Copy link
Member

anselmh commented Oct 25, 2016

Okay folks, thanks for the feedback on it, we changed the example now to a better default value. 😊

@anselmh anselmh closed this as completed Oct 25, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants