1
0
Fork 0
docsearch/.circleci/config.yml
Paul Jankowski 171c504f11
feat(sidepanel): Introduce Ask AI Sidepanel (#2816)
* feat(sidepanel): Add sidepanel component for Ask AI (#2792)

* feat(sidepanel): Initial working Sidepanel implementation

* fix: circleci config

* fix: set proper sidepanel export

* Sidepanel props updates, conversation screen updates

* Started mobile work

* Style prompt input and header for mobile

* fixes prompt input height, adds more translations, mobile updates, fixes panel height calculations

* finish mobile, adds dark theme, minor fixes

* fix: lock

* Add missing titles to buttons

* Have most recent conversation be at the bottom of the exchange list, scroll to newest conversation

* fix: versions

* move to floating variant being default for Sidepanel

---------

Co-authored-by: Dylan Tientcheu <dylantientcheu@gmail.com>

* feat(sidepanel): Sidepanel/Modal hybrid mode (#2799)

* feat(sidepanel): Initial working Sidepanel implementation

* fix: circleci config

* fix: set proper sidepanel export

* Sidepanel props updates, conversation screen updates

* Started mobile work

* Style prompt input and header for mobile

* fixes prompt input height, adds more translations, mobile updates, fixes panel height calculations

* finish mobile, adds dark theme, minor fixes

* fix: lock

* Add missing titles to buttons

* Have most recent conversation be at the bottom of the exchange list, scroll to newest conversation

* feat(sidepanel): Allow hybrid mode for Sidepanel and Modal

* fix: yarn.lock

* fix: tests - dont send new chat message from modal while in hybrid mode

* Make docsearch core a true dependency

* Cleanup handling the registered views Set

---------

Co-authored-by: Dylan Tientcheu <dylantientcheu@gmail.com>

* feat(sidepanel): Add sidepanel-js package for CDN (#2800)

* feat(sidepanel): Initial working Sidepanel implementation

* fix: circleci config

* fix: set proper sidepanel export

* Sidepanel props updates, conversation screen updates

* Started mobile work

* Style prompt input and header for mobile

* fixes prompt input height, adds more translations, mobile updates, fixes panel height calculations

* finish mobile, adds dark theme, minor fixes

* fix: lock

* Add missing titles to buttons

* Have most recent conversation be at the bottom of the exchange list, scroll to newest conversation

* feat(sidepanel): Add sidepanel-js package for CDN

* fix: ci

* fix: yarn.lock

---------

Co-authored-by: Dylan Tientcheu <dylantientcheu@gmail.com>

* feat(sidepanel): Sidepanel UI/UX tweaks (#2808)

* fix(umd): Fixes global names for packages in UMD builds

* chore: Update tsdeclaration files, update directory field in package json files

* feat(sidepanel): Add Sidepanel documentation (#2811)

* feat(sidepanel): Add Sidepanel documentation

* Minor fixes and updates

* Hybrid mode update

* fix: hardcode yarn cache key for now

---------

Co-authored-by: Dylan Tientcheu <dylantientcheu@gmail.com>
2025-12-17 13:25:50 -05:00

201 lines
5.9 KiB
YAML

version: 2.1
aliases:
- &restore_yarn_cache
name: Restore Yarn cache
keys:
- yarn-packages-sidepanel-{{ checksum "yarn.lock" }}
- &save_yarn_cache
name: Save Yarn cache
key: yarn-packages-sidepanel-{{ checksum "yarn.lock" }}
paths:
- .yarn/cache
- .yarn/unplugged
- &run_yarn_install
name: Install dependencies
command: yarn install --immutable
- &restore_dist_folders
name: Restore dist folders
command: |
set -exu
mkdir -p packages/docsearch-react/dist
mkdir -p packages/docsearch-js/dist
mkdir -p packages/docsearch-css/dist
mkdir -p packages/docsearch-core/dist
mkdir -p packages/docsearch-modal/dist
mkdir -p packages/docsearch-sidepanel/dist
mkdir -p packages/docsearch-sidepanel-js/dist
cp -R /tmp/workspace/packages/docsearch-react/dist packages/docsearch-react
cp -R /tmp/workspace/packages/docsearch-js/dist packages/docsearch-js
cp -R /tmp/workspace/packages/docsearch-css/dist packages/docsearch-css
cp -R /tmp/workspace/packages/docsearch-core/dist packages/docsearch-core
cp -R /tmp/workspace/packages/docsearch-modal/dist packages/docsearch-modal
cp -R /tmp/workspace/packages/docsearch-sidepanel/dist packages/docsearch-sidepanel
cp -R /tmp/workspace/packages/docsearch-sidepanel-js/dist packages/docsearch-sidepanel-js
defaults: &defaults
working_directory: ~/docsearch
docker:
- image: cimg/node:22.15.0
cypress: &cypress
working_directory: ~/docsearch
docker:
- image: cypress/browsers:node-22.15.0-chrome-136.0.7103.113-1-ff-138.0.3-edge-136.0.3240.64-1
environment:
## this enables colors in the output
TERM: xterm
references:
workspace_root: &workspace_root /tmp/workspace
attach_workspace: &attach_workspace
attach_workspace:
at: *workspace_root
jobs:
build:
<<: *defaults
steps:
- checkout
- restore_cache: *restore_yarn_cache
- run: *run_yarn_install
- save_cache: *save_yarn_cache
- run:
name: Build and Size
command: |
yarn run build
- run:
name: Move dist folders to workspace
command: |
set -exu
mkdir -p /tmp/workspace/packages/docsearch-react/dist
mkdir -p /tmp/workspace/packages/docsearch-js/dist
mkdir -p /tmp/workspace/packages/docsearch-css/dist
mkdir -p /tmp/workspace/packages/docsearch-core/dist
mkdir -p /tmp/workspace/packages/docsearch-modal/dist
mkdir -p /tmp/workspace/packages/docsearch-sidepanel/dist
mkdir -p /tmp/workspace/packages/docsearch-sidepanel-js/dist
cp -R packages/docsearch-react/dist /tmp/workspace/packages/docsearch-react
cp -R packages/docsearch-js/dist /tmp/workspace/packages/docsearch-js
cp -R packages/docsearch-css/dist /tmp/workspace/packages/docsearch-css
cp -R packages/docsearch-core/dist /tmp/workspace/packages/docsearch-core
cp -R packages/docsearch-modal/dist /tmp/workspace/packages/docsearch-modal
cp -R packages/docsearch-sidepanel/dist /tmp/workspace/packages/docsearch-sidepanel
cp -R packages/docsearch-sidepanel-js/dist /tmp/workspace/packages/docsearch-sidepanel-js
- persist_to_workspace:
root: *workspace_root
paths:
- packages
test_lint:
<<: *defaults
steps:
- checkout
- *attach_workspace
- restore_cache: *restore_yarn_cache
- run: *run_yarn_install
- save_cache: *save_yarn_cache
- run: *restore_dist_folders
- run:
name: Linting
command: yarn run lint
test_types:
<<: *defaults
steps:
- checkout
- *attach_workspace
- restore_cache: *restore_yarn_cache
- run: *run_yarn_install
- save_cache: *save_yarn_cache
- run: *restore_dist_folders
- run:
name: Type checking
command: yarn run test:types
test_size:
<<: *defaults
steps:
- checkout
- *attach_workspace
- restore_cache: *restore_yarn_cache
- run: *run_yarn_install
- save_cache: *save_yarn_cache
- run: *restore_dist_folders
- run:
name: Size checking
command: yarn run test:size
test_unit:
<<: *defaults
steps:
- checkout
- *attach_workspace
- restore_cache: *restore_yarn_cache
- run: *run_yarn_install
- save_cache: *save_yarn_cache
- run: *restore_dist_folders
- run:
name: Unit tests
command: yarn run test
release:
<<: *defaults
steps:
- checkout
- *attach_workspace
- restore_cache: *restore_yarn_cache
- run: *run_yarn_install
- save_cache: *save_yarn_cache
- run: *restore_dist_folders
- run:
name: Setup git user
command: |
git config --global user.email "accounts+algolia-api-client-bot@algolia.com"
git config --global user.name "algolia-bot"
- run:
name: Release if needed
command: yarn run shipjs trigger
test_cypress:
<<: *cypress
steps:
- checkout
- *attach_workspace
- restore_cache: *restore_yarn_cache
- run: *run_yarn_install
- save_cache: *save_yarn_cache
- run: *restore_dist_folders
- run:
name: Cypress test Actions
command: yarn run cy:run
workflows:
version: 2
ci:
jobs:
- build
- test_lint:
requires:
- build
- test_types:
requires:
- build
- test_size:
requires:
- build
- test_unit:
requires:
- build
- test_cypress:
requires:
- build
- release:
requires:
- build
filters:
branches:
only:
- main
- /v[0-9]+/