Skip to content

Commit

Permalink
Included styles and tailwind
Browse files Browse the repository at this point in the history
  • Loading branch information
Willem Toerien committed Oct 25, 2024
1 parent a3c7362 commit 5d4dcbf
Show file tree
Hide file tree
Showing 86 changed files with 15 additions and 5 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
/tmp
/out-tsc
/bazel-out
public-api.ts

# Node
/node_modules
Expand Down
6 changes: 5 additions & 1 deletion projects/wtprograms/material-design/ng-package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,9 @@
"dest": "../../../dist/wtprograms/material-design",
"lib": {
"entryFile": "src/public-api.ts"
}
},
"assets": [
"styles",
"tailwind"
]
}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
@forward '../../styles/index';
@forward '../../../styles/index';
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,11 @@ $sizes: ('large', 'medium', 'small');

@each $scale in $scales {
@each $size in $sizes {
:host([scale='#{$scale}'][size='#{$size}']) {
:host([scale='#{$scale}'][size='#{$size}'][rfs='true']) {
@include md.typescale($scale, $size);
}
:host([scale='#{$scale}'][size='#{$size}']:not([rfs='true'])) {
@include md.typescale($scale, $size, false);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,11 @@ export type TypescaleSize = 'large' | 'medium' | 'small';
host: {
'[attr.scale]': 'scale()',
'[attr.size]': 'size()',
'[attr.rfs]': 'rfs() ?? null',
},
})
export class TypescaleComponent extends MaterialDesignComponent {
readonly scale = model<Typescale>('body');
readonly size = model<TypescaleSize>('medium');
readonly rfs = model(true);
}
2 changes: 1 addition & 1 deletion src/styles.scss
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@use '../projects/wtprograms/material-design/src/styles/index' as md;
@use '../projects/wtprograms/material-design/styles/index' as md;

@include md.import;
@include md.reboot;
Expand Down
2 changes: 1 addition & 1 deletion tailwind.config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const md = require("./projects/wtprograms/material-design/src/tailwind");
const md = require("./projects/wtprograms/material-design/tailwind");

/** @type {import('tailwindcss').Config} */
module.exports = {
Expand Down

0 comments on commit 5d4dcbf

Please sign in to comment.