-
Notifications
You must be signed in to change notification settings - Fork 70
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
Optimize calc() usage in scss files #1158
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Nuraiym Omurbekova <nuraikaomurbek@gmail.com> Co-authored-by: Josh Romero <rmerqg@amazon.com> Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
Also: * Implement sass variable extraction * Implement sass variable importing in typescript * Add guards to post-install cleanup * Make sources compatible with dart sass by wrapping divisions in `calc()` and adding units were necessary * Fold in `@elastic/charts/dist/theme.scss` to modify it for dart-sass compatibility * Break out compiling `charts` Signed-off-by: Miki <miki@amazon.com> Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
* typescript bump: 4.1.6 Signed-off-by: Danila Gulderov <danila@gulderov.me> * typescript bump: 4.2.4 Signed-off-by: Danila Gulderov <danila@gulderov.me> * typescript bump: 4.3.5 Signed-off-by: Danila Gulderov <danila@gulderov.me> * typescript bump: 4.4.4 Signed-off-by: Danila Gulderov <danila@gulderov.me> * typescript bump: 4.5.5 Signed-off-by: Danila Gulderov <danila@gulderov.me> * typescript bump: 4.6.4 Signed-off-by: Danila Gulderov <danila@gulderov.me> * CHANGELOG.md updated Signed-off-by: Danila Gulderov <danila@gulderov.me> * bump typescript-eslint/eslint-plugin: 5.62.0 bump typescript-eslint/parser: 5.62.0 node 16 is required for typescript-eslint: 6.0.0 Signed-off-by: Danila Gulderov <danila@gulderov.me> * CHANGELOG.md update Signed-off-by: Danila Gulderov <danila@gulderov.me> * move typescript update to regular section Signed-off-by: Danila Gulderov <danila@gulderov.me> * changelog message improvement Signed-off-by: Danila Gulderov <danila@gulderov.me> * fix typings Signed-off-by: Danila Gulderov <danila@gulderov.me> * cleanup useUnknownInCatchVariables Signed-off-by: Danila Gulderov <danila@gulderov.me> * logical or => nullish coalescing Signed-off-by: Danila Gulderov <danila@gulderov.me> * wrap with String Signed-off-by: Danila Gulderov <danila@gulderov.me> * Update CHANGELOG.md Move CHANGELOG entry to the unreleased section Signed-off-by: Miki <miki@amazon.com> * Add back `onPinClick` check in `OuiPinnableListGroup` Update pinnable_list_group.tsx Signed-off-by: Miki <miki@amazon.com> * Enhance error message extraction in `validateFieldValue` Update default_syntax.ts Signed-off-by: Miki <miki@amazon.com> * Remove e.code from default_syntax.ts Update default_syntax.ts Signed-off-by: Miki <miki@amazon.com> * Lint default_syntax.ts Signed-off-by: Miki <miki@amazon.com> --------- Signed-off-by: Danila Gulderov <danila@gulderov.me> Signed-off-by: Matt Provost <provomat@amazon.com> Signed-off-by: Miki <miki@amazon.com> Co-authored-by: Matt Provost <provomat@amazon.com> Co-authored-by: Josh Romero <rmerqg@amazon.com> Co-authored-by: Miki <miki@amazon.com> Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
Signed-off-by: Shahriar Shatil <52494840+ShatilKhan@users.noreply.github.com> Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
Signed-off-by: Shahriar Shatil <52494840+ShatilKhan@users.noreply.github.com> Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
Signed-off-by: Shahriar Shatil <52494840+ShatilKhan@users.noreply.github.com> Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
On line 88, in order to optimize We perform the subtraction within the map-get function directly. This simplifies the calculation by removing the unnecessary parentheses around map-get($map, 'percentage'). Signed-off-by: Shahriar Shatil <52494840+ShatilKhan@users.noreply.github.com> Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
Signed-off-by: Shahriar Shatil <52494840+ShatilKhan@users.noreply.github.com> Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
Signed-off-by: Shahriar Shatil <52494840+ShatilKhan@users.noreply.github.com> Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
Signed-off-by: Shahriar Shatil <52494840+ShatilKhan@users.noreply.github.com> Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
Signed-off-by: Shahriar Shatil <52494840+ShatilKhan@users.noreply.github.com> Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
Signed-off-by: Shahriar Shatil <52494840+ShatilKhan@users.noreply.github.com> Signed-off-by: ShatilKhan <shatilshahriar009@gmail.com>
I'm just gonna make a new PR, a lot of problem with this one |
@ShatilKhan Those lines indicate a merge conflict, where git is unsure whether which branch has the "correct" or desired changes. So it keeps both and wraps them in those markers so that you can manually choose (or replace with a combination). The first section is the line(s) as it appears in the |
Thanks for the explanation @joshuarrrr |
Signed-off-by: Shahriar Shatil <52494840+ShatilKhan@users.noreply.github.com>
I resolved all the conflicts |
It looks like the linter is throwing errors: https://github.com/opensearch-project/oui/actions/runs/7163472679/job/19525060011?pr=1158#step:5:17 Also looks like build got broken: https://github.com/opensearch-project/oui/actions/runs/7163472679/job/19525059465?pr=1158#step:5:123 |
Signed-off-by: Shahriar Shatil <52494840+ShatilKhan@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed linting failures
Signed-off-by: Shahriar Shatil <52494840+ShatilKhan@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A lot of the changes are unnecessary and in fact, detrimental to readability and maintainability.
const util = require('util') | ||
const { writeFile, mkdir } = require('fs/promises' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What happened here? Please revert.
@@ -64,4 +65,5 @@ module.exports = (babel) => ({ | |||
} | |||
}, | |||
}, | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove unnecessary space.
@@ -28,6 +28,7 @@ | |||
* under the License. | |||
*/ | |||
|
|||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove unnecessary space.
await Promise.all | ||
inputFilenames.map(async (inputFilename) => |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please revert.
chalk`{green ✔} Finished compiling {gray ${inputFilename}} to ${outputFilename | ||
.map((filename) => chalk.gray(filename) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please revert
Description
Optimization of some math equations inside
calc()
inscss
files was done.Issues Resolved
Fixes #1002
Check List
yarn lint
yarn test-unit
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.