Before submitting...
Context
When building a project with materializecss/materialize as a dependency, styling configuration sources and component sources are missing
This results in a backward compatibility bug
Current Behavior
Requiring materializecss/materialize as dependency and building from source in a specific workflow (e.g. rollup, webpack, ...) results in a chain of forward references not found
Expected behavior
Since component sources are included in distributed package, css forward should not result in missing packages or forward statements should be refactored to desired output
Possible Solutions or Causes
As seen in materialize.scss
|
@forward "../node_modules/normalize.css/normalize.css"; |
|
@forward "./tokens.module.css"; |
|
@forward "./theme.module.css"; |
|
@forward "./typography.module.css"; |
|
@forward "./colors.module.css"; |
|
@forward "./typography"; |
|
@forward "./mixins.module"; |
|
@forward "./transitions.css"; |
|
@forward "./pulse.css"; |
|
@forward "../components/buttons/buttons"; |
|
@forward "../components/lists/collection"; |
|
@forward "../components/collapsible/collapsible"; // custom |
|
@forward "../components/badges/badges"; |
|
@forward "../components/cards/cards"; |
|
@forward "../components/snackbar/toast"; |
|
@forward "../components/tabs/tabs"; |
|
@forward "../components/tooltips/tooltip"; |
|
@forward "../components/dropdown/dropdown"; |
|
@forward "../components/dialog/modal"; |
|
@forward "../components/dialog/materialbox"; // custom |
|
@forward "../components/chips/chips"; |
|
@forward "../components/navigation-bar/navbar"; |
|
@forward "../components/navigation-drawer/sidenav"; |
|
@forward "../components/progress-indicators/preloader"; |
|
@forward "../components/carousel/slider"; |
|
@forward "../components/carousel/carousel"; |
|
@forward "../components/datepicker/datepicker"; |
|
@forward "../components/timepicker/timepicker"; |
|
@forward "../components/breadcrumb/breadcrumb"; // custom |
|
@forward "../components/pagination/pagination"; //custom |
|
@forward '../components/radio-button/radio-buttons'; |
|
@forward '../components/checkbox/checkboxes'; |
|
@forward '../components/switch/switches'; |
|
@forward '../components/sliders/range'; |
|
@forward '../components/text-fields/input-fields'; |
|
@forward '../components/text-fields/select'; |
|
@forward '../components/text-fields/file-input'; |
Missing in distributed package
https://www.npmjs.com/package/@materializecss/materialize/v/2.3.0?activeTab=code
Steps to reproduce
- require materializecss/materialize by npm e.g.
npm init + npm install @materializecss/materialize@2.3.0
- implement workflow to build from source e.g. by providing
node_modules/@materializecss/materialize/sass/materialize.scss as input file, rollup example for standalone materialize sass compilation:
{
input: 'node_modules/@materializecss/materialize/sass/materialize.scss',
output: [{file: 'dist/materialize.css'}], // overwritten
plugins: [
scss({
fileName: 'materialize.css'
})
],
}
Your Environment
Before submitting...
Context
When building a project with
materializecss/materializeas a dependency, styling configuration sources and component sources are missingThis results in a backward compatibility bug
Current Behavior
Requiring
materializecss/materializeas dependency and building from source in a specific workflow (e.g. rollup, webpack, ...) results in a chain of forward references not foundExpected behavior
Since component sources are included in distributed package, css forward should not result in missing packages or forward statements should be refactored to desired output
Possible Solutions or Causes
As seen in materialize.scss
materialize/sass/materialize.scss
Lines 3 to 9 in ce3e251
materialize/sass/materialize.scss
Lines 15 to 16 in ce3e251
materialize/sass/materialize.scss
Lines 21 to 48 in ce3e251
Missing in distributed package
https://www.npmjs.com/package/@materializecss/materialize/v/2.3.0?activeTab=code
Steps to reproduce
npm init+npm install @materializecss/materialize@2.3.0node_modules/@materializecss/materialize/sass/materialize.scssas input file, rollup example for standalone materialize sass compilation:Your Environment