Skip to content

Commit

Permalink
fix: hide rendered style elements (#536)
Browse files Browse the repository at this point in the history
* fix: fixed issue when refreshing with dot in URL

* fix: remove display block from style tags
  • Loading branch information
lem-onade authored Dec 15, 2021
1 parent dcdb514 commit 103688e
Show file tree
Hide file tree
Showing 7 changed files with 42 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -101,11 +101,12 @@ export class PaginatorComponent extends RxLitElement {
justify-content: flex-end;
gap: var(--gap-normal);
height: var(--gap-normal);
width: 100%;
}
:host[hidden] {
display: none;
}
:host > * {
:host > *:not(style) {
margin: 0;
padding: 0;
display: block;
Expand Down
15 changes: 15 additions & 0 deletions packages/solid-crs-manage/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion packages/solid-crs-manage/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@
"ts-node": "^9.1.1",
"typescript": "^4.2.4",
"util": "^0.12.4",
"vite": "2.2.3"
"vite": "2.2.3",
"vite-plugin-rewrite-all": "^0.1.2"
},
"publishConfig": {
"registry": "https://npm.pkg.github.com/"
Expand Down
3 changes: 3 additions & 0 deletions packages/solid-crs-manage/vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { defineConfig, loadEnv } from 'vite';
import pluginRewriteAll from 'vite-plugin-rewrite-all';

export default defineConfig( ({ command, mode }) => {
const env = loadEnv(mode, process.cwd());
Expand All @@ -22,6 +23,8 @@ export default defineConfig( ({ command, mode }) => {

if (command === 'serve') {
return {
// fixes 404 errors with dots in URL when serving locally (https://github.com/vitejs/vite/issues/2415)
plugins: [ pluginRewriteAll() ],
root: 'lib',
server: {
port: 3002,
Expand Down
15 changes: 15 additions & 0 deletions packages/solid-crs-presentation/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion packages/solid-crs-presentation/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,8 @@
"ts-node": "^9.1.1",
"typescript": "^4.2.4",
"util": "^0.12.4",
"vite": "2.2.3"
"vite": "2.2.3",
"vite-plugin-rewrite-all": "^0.1.2"
},
"publishConfig": {
"registry": "https://npm.pkg.github.com/"
Expand Down
3 changes: 3 additions & 0 deletions packages/solid-crs-presentation/vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { defineConfig, loadEnv } from 'vite';
import pluginRewriteAll from 'vite-plugin-rewrite-all';

export default defineConfig( ({ command, mode }) => {
const env = loadEnv(mode, process.cwd());
Expand All @@ -19,6 +20,8 @@ export default defineConfig( ({ command, mode }) => {

if (command === 'serve') {
return {
// fixes 404 errors with dots in URL when serving locally (https://github.com/vitejs/vite/issues/2415)
plugins: [ pluginRewriteAll() ],
root: 'lib',
server: {
port: 3005,
Expand Down

0 comments on commit 103688e

Please sign in to comment.