From 9a2188548c446fc195bd009f220a1958a4a3e934 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Chalifour?= Date: Thu, 9 Jul 2020 12:15:04 +0200 Subject: [PATCH] feat(website): lazy load DocSearch styles --- package.json | 4 ++-- style/button.js | 1 + style.js => style/index.js | 0 style/modal.js | 1 + style/variables.js | 1 + 5 files changed, 5 insertions(+), 2 deletions(-) create mode 100644 style/button.js rename style.js => style/index.js (100%) create mode 100644 style/modal.js create mode 100644 style/variables.js diff --git a/package.json b/package.json index 34da1e1d..39d9a684 100644 --- a/package.json +++ b/package.json @@ -11,9 +11,9 @@ "sideEffects": false, "files": [ "dist/", + "style/", "button.js", - "modal.js", - "style.js" + "modal.js" ], "source": "src/index.ts", "types": "dist/esm/index.d.ts", diff --git a/style/button.js b/style/button.js new file mode 100644 index 00000000..86e69d1f --- /dev/null +++ b/style/button.js @@ -0,0 +1 @@ +export * from '@docsearch/css/dist/button.css'; diff --git a/style.js b/style/index.js similarity index 100% rename from style.js rename to style/index.js diff --git a/style/modal.js b/style/modal.js new file mode 100644 index 00000000..fb35bb60 --- /dev/null +++ b/style/modal.js @@ -0,0 +1 @@ +export * from '@docsearch/css/dist/modal.css'; diff --git a/style/variables.js b/style/variables.js new file mode 100644 index 00000000..ecbb7b20 --- /dev/null +++ b/style/variables.js @@ -0,0 +1 @@ +export * from '@docsearch/css/dist/_variables.css';