diff --git a/examples/js/package.json b/examples/js/package.json index d8b94723f..010e0e6dd 100644 --- a/examples/js/package.json +++ b/examples/js/package.json @@ -15,6 +15,7 @@ "@algolia/autocomplete-plugin-query-suggestions": "1.0.0-alpha.35", "@algolia/autocomplete-plugin-recent-searches": "1.0.0-alpha.35", "@algolia/autocomplete-preset-algolia": "1.0.0-alpha.35", + "@algolia/autocomplete-theme-classic": "1.0.0-alpha.35", "algoliasearch": "4.7.0", "search-insights": "1.6.2" }, diff --git a/examples/react-renderer/package.json b/examples/react-renderer/package.json index 76fdcbbf8..54dec53cd 100644 --- a/examples/react-renderer/package.json +++ b/examples/react-renderer/package.json @@ -6,6 +6,7 @@ "dependencies": { "@algolia/autocomplete-core": "1.0.0-alpha.35", "@algolia/autocomplete-preset-algolia": "1.0.0-alpha.35", + "@algolia/autocomplete-theme-classic": "1.0.0-alpha.35", "algoliasearch": "4.8.0", "react": "17.0.1", "react-dom": "17.0.1", diff --git a/examples/react-renderer/src/autocomplete.css b/examples/react-renderer/src/autocomplete.css deleted file mode 100644 index 7012d4498..000000000 --- a/examples/react-renderer/src/autocomplete.css +++ /dev/null @@ -1,144 +0,0 @@ -.aa-Form { - position: relative; -} - -.aa-Label { - align-items: center; - color: #777; - cursor: initial; - display: flex; - height: 100%; - padding: 0 0.5rem; - position: absolute; - z-index: 2; -} - -.aa-InputWrapper { - background-color: #fff; - max-width: 100%; - min-height: 2.5rem; - position: relative; - width: 100%; -} - -.aa-Input { - appearance: none; - background: none; - border: 1px solid #d6d6e7; - border-radius: 3px; - box-shadow: rgba(119, 122, 175, 0.3) 0 1px 4px 0 inset; - caret-color: #5a5e9a; - color: #23263b; - font: inherit; - height: 100%; - position: absolute; - width: 100%; - z-index: 2; -} - -.aa-Input::-webkit-search-decoration, -.aa-Input::-webkit-search-cancel-button, -.aa-Input::-webkit-search-results-button, -.aa-Input::-webkit-search-results-decoration { - -webkit-appearance: none; -} - -.aa-Input { - padding: 0 2.25rem; -} - -.aa-Input::placeholder { - color: #5a5e9a; -} - -.aa-Input:focus { - border-color: #3c4fe0; - box-shadow: rgba(35, 38, 59, 0.05) 0 1px 0 0; - outline: currentcolor none medium; -} - -.aa-ResetButton { - background: none; - border: 0; - cursor: pointer; - height: 100%; - padding: 0 0.5rem; - position: absolute; - right: 0; - z-index: 2; -} - -.aa-Panel { - max-width: 480px; - position: absolute; - width: 100%; -} - -.aa-Panel--stalled { - filter: grayscale(1); - opacity: 0.5; - transition: opacity 200ms ease-in; -} - -.aa-PanelLayout { - background-color: #fff; - border: 1px solid rgba(150, 150, 150, 0.16); - border-radius: 3px; - box-shadow: 0 0 0 1px rgba(35, 38, 59, 0.05), - 0 8px 16px -4px rgba(35, 38, 59, 0.25); - margin-top: 5px; -} - -.aa-PanelLayout a { - color: inherit; - text-decoration: none; -} - -.aa-PanelLayout ul { - list-style: none; - margin: 0; - padding: 0; -} - -.aa-Item { - color: #23263b; - cursor: pointer; - display: flex; - grid-gap: 0.5rem; - justify-content: space-between; -} - -.aa-Item mark { - background: none; - font-style: normal; - font-weight: bold; -} - -.aa-Item[aria-selected='true'] { - background-color: #f5f5fa; -} - -.aa-ItemContent { - display: flex; - flex-grow: 1; - grid-gap: 0.5rem; - padding: 0.5rem; -} - -.aa-ItemSourceIcon, -.aa-ItemActionButton { - color: rgba(80, 80, 80, 0.32); -} - -.aa-ItemActionButton { - background-color: transparent; - border: 0; - cursor: pointer; - opacity: 0.8; - padding: 0.5rem; - transition: color 100ms; -} - -.aa-ItemActionButton:hover { - color: rgba(80, 80, 80, 1); -} diff --git a/examples/react-renderer/src/index.tsx b/examples/react-renderer/src/index.tsx index ce432434d..2bc03e86b 100644 --- a/examples/react-renderer/src/index.tsx +++ b/examples/react-renderer/src/index.tsx @@ -1,9 +1,10 @@ import React from 'react'; import ReactDOM from 'react-dom'; +import '@algolia/autocomplete-theme-classic'; + import './reset.css'; import './index.css'; -import './autocomplete.css'; import { App } from './App'; ReactDOM.render( diff --git a/packages/autocomplete-theme-classic/package.json b/packages/autocomplete-theme-classic/package.json index 66c72395e..4b4b2d272 100644 --- a/packages/autocomplete-theme-classic/package.json +++ b/packages/autocomplete-theme-classic/package.json @@ -1,7 +1,7 @@ { "name": "@algolia/autocomplete-theme-classic", "description": "Classic theme for Algolia Autocomplete.", - "version": "1.0.0-alpha.34", + "version": "1.0.0-alpha.35", "license": "MIT", "homepage": "https://github.com/algolia/autocomplete.js", "repository": "algolia/autocomplete.js", diff --git a/scripts/rollup/config.js b/scripts/rollup/config.js index 778831153..9545962c7 100644 --- a/scripts/rollup/config.js +++ b/scripts/rollup/config.js @@ -5,7 +5,7 @@ import babel from 'rollup-plugin-babel'; import filesize from 'rollup-plugin-filesize'; import { terser } from 'rollup-plugin-terser'; -import { getBundleBanner } from '../getBundleBanner'; +import { getBundleBanner } from '../getBundleBanner.mjs'; const BUILD_MODES = ['development', 'production']; const extensions = ['.js', '.jsx', '.ts', '.tsx', '.json'];