Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -762,6 +762,28 @@ jobs:
paths:
- '*/verdaccio/publish-stats'

v-starters:
executor: rsp-xlarge
steps:
- restore_cache:
key: react-spectrum-{{ .Environment.CACHE_VERSION }}-{{ .Environment.CIRCLE_SHA1 }}

- attach_workspace:
at: /tmp/verdaccio-workspace

- run:
name: build s2-next off verdaccio
command: |
./scripts/verdaccio-ci.sh
./scripts/verdaccio-build-starters.sh
environment:
VERDACCIO_STORAGE_PATH: /tmp/verdaccio-workspace/storage

- persist_to_workspace:
root: dist
paths:
- 's2-docs/'

deploy:
docker:
- image: mcr.microsoft.com/azure-cli:2.63.0
Expand Down Expand Up @@ -987,6 +1009,9 @@ workflows:
- v-webpack-4
- v-nextjs
- v-rsp-cra-18
- v-starters:
requires:
- verdaccio
- deploy:
requires:
- lint
Expand All @@ -1013,6 +1038,7 @@ workflows:
requires:
- s2-docs
- s2-docs-stage
- v-starters
filters:
branches:
only: main
Expand Down
10 changes: 5 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,6 @@ s2-docs-stage:
DOCS_ENV=stage PUBLIC_URL=/ $(MAKE) build-s2-docs
cp packages/dev/docs/pages/disallow-robots.txt dist/s2-docs/react-aria/robots.txt
cp packages/dev/docs/pages/disallow-robots.txt dist/s2-docs/s2/robots.txt
$(MAKE) build-starters

s2-docs-production:
DOCS_ENV=prod PUBLIC_URL=/ $(MAKE) build-s2-docs
Expand Down Expand Up @@ -187,7 +186,8 @@ build-s2-docs:
build-starters:
$(MAKE) starter-zip
$(MAKE) tailwind-starter
mv starters/docs/storybook-static dist/s2-docs/react-aria-starter
mv starters/docs/react-aria-starter.zip dist/s2-docs/react-aria-starter.$$(git rev-parse --short HEAD).zip
mv starters/tailwind/storybook-static dist/s2-docs/react-aria-tailwind-starter
mv starters/tailwind/react-aria-tailwind-starter.zip dist/s2-docs/react-aria-tailwind-starter.$$(git rev-parse --short HEAD).zip
mkdir -p dist/s2-docs/react-aria/$(PUBLIC_URL)
mv starters/docs/storybook-static dist/s2-docs/react-aria/$(PUBLIC_URL)/react-aria-starter
mv starters/docs/react-aria-starter.zip dist/s2-docs/react-aria/$(PUBLIC_URL)/react-aria-starter.$$(git rev-parse --short HEAD).zip
mv starters/tailwind/storybook-static dist/s2-docs/react-aria/$(PUBLIC_URL)/react-aria-tailwind-starter
mv starters/tailwind/react-aria-tailwind-starter.zip dist/s2-docs/react-aria/$(PUBLIC_URL)/react-aria-tailwind-starter.$$(git rev-parse --short HEAD).zip
5 changes: 4 additions & 1 deletion packages/@react-spectrum/s2/src/DateField.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,9 @@ const segmentContainer = style({
flexShrink: 1,
minWidth: 0,
height: 'full',
overflow: 'hidden',
overflowX: 'auto',
overflowY: 'hidden',
scrollbarWidth: 'none',
display: 'flex',
alignItems: 'center',
textWrap: 'nowrap'
Expand Down Expand Up @@ -144,6 +146,7 @@ export const DateField = /*#__PURE__*/ (forwardRef as forwardRefType)(function D
size={size}
styles={style({
...fieldInput(),
textWrap: 'nowrap',
paddingX: 'edge-to-text'
})({size})}>
<DateInputContainer>
Expand Down
1 change: 1 addition & 0 deletions packages/@react-spectrum/s2/style/spectrum-theme.ts
Original file line number Diff line number Diff line change
Expand Up @@ -952,6 +952,7 @@ export const style = createTheme({
overscrollBehaviorX: ['auto', 'contain', 'none'] as const,
overscrollBehaviorY: ['auto', 'contain', 'none'] as const,
scrollBehavior: ['auto', 'smooth'] as const,
scrollbarWidth: ['none', 'auto', 'thin'] as const,
order: new ArbitraryProperty<number>('order'),

pointerEvents: ['none', 'auto'] as const,
Expand Down
39 changes: 39 additions & 0 deletions scripts/verdaccio-build-starters.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
#!/usr/bin/env bash

port=4000
registry="http://localhost:$port"
output="output.out"
touch $output

set -e

echo "Building starters with verdaccio"

# Wait for verdaccio to start
grep -q 'http address' <(tail -f $output)

if curl -sI http://localhost:4000/ >/dev/null; then
echo "Verdaccio is running on port 4000."
else
echo "Verdaccio is NOT running on port 4000."
fi

yarn config set npmPublishRegistry --home $registry
yarn config set npmRegistryServer --home $registry
yarn config set npmAlwaysAuth --home false
yarn config set npmAuthToken --home abc
yarn config set unsafeHttpWhitelist --home localhost
npm set registry $registry

cd starters/docs
yarn config set npmRegistryServer $registry
yarn install --no-immutable
yarn up react-aria-components
cd ../tailwind
yarn config set npmRegistryServer $registry
yarn install --no-immutable
yarn up react-aria-components tailwindcss-react-aria-components
cd ../..
make build-starters

netstat -tpln | awk -F'[[:space:]/:]+' '$5 == 4000 {print $(NF-2)}' | xargs kill
2 changes: 2 additions & 0 deletions scripts/verdaccio-deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ registry="http://localhost:$port"
output="output.out"
touch $output

set -e

echo "Build and deploy to verdaccio"

# Wait for verdaccio to start
Expand Down
2 changes: 1 addition & 1 deletion scripts/verdaccio-generate-versions.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ process.stdin.on('end', () => {
if (location.startsWith('packages/dev/')) {
const packageName = location.split('/').pop();
// Only include specific dev tools
if (['optimize-locales-plugin', 'parcel-resolver-optimize-locales', 'codemods', 'mcp',
if (location.includes('mcp') || ['optimize-locales-plugin', 'parcel-resolver-optimize-locales', 'codemods',
'parcel-transformer-s2-icon', 's2-icon-builder', 'ts-plugin', 'parcel-namer-s2'].includes(packageName)) {
acc[workspace.name] = 'patch';
}
Expand Down
Binary file modified starters/docs/.yarn/install-state.gz
Binary file not shown.
8 changes: 4 additions & 4 deletions starters/docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,17 @@
"@storybook/react": "^8.6.14",
"@storybook/react-webpack5": "^8.6.14",
"@storybook/test": "^8.6.14",
"@types/react": "^18.3.0",
"@types/react-dom": "^18.3.0",
"@types/react": "^19.1.0",
"@types/react-dom": "^19.1.0",
"clsx": "^2.1.1",
"lightningcss-loader": "^2.1.0",
"lucide-react": "^0.517.0",
"react": "^19.1.0",
"react-aria-components": "latest",
"react-aria-components": "^1.13.0",
"react-dom": "^19.1.0",
"storybook": "^8.6.14",
"storybook-dark-mode": "^4.0.2",
"typescript": "5.3.3"
"typescript": "^5.8.2"
},
"resolutions": {
"react": "19.1.0",
Expand Down
36 changes: 20 additions & 16 deletions starters/docs/stories/Menu.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,31 +1,35 @@
import {Menu, MenuButton, MenuItem, SubmenuTrigger} from '../src/Menu';
import {Menu, MenuTrigger, MenuItem, SubmenuTrigger} from '../src/Menu';
import {Button} from '../src/Button';

import type {Meta, StoryFn} from '@storybook/react';

const meta: Meta<typeof MenuButton> = {
component: MenuButton,
const meta: Meta<typeof Menu> = {
component: Menu,
parameters: {
layout: 'centered'
},
tags: ['autodocs']
};

export default meta;
type Story = StoryFn<typeof MenuButton>;
type Story = StoryFn<typeof Menu>;

export const Example: Story = (args) => (
<MenuButton label="Edit" {...args}>
<MenuItem>Favorite</MenuItem>
<MenuItem>Edit</MenuItem>
<MenuItem>Delete</MenuItem>
<SubmenuTrigger>
<MenuItem>Share</MenuItem>
<Menu>
<MenuItem>SMS</MenuItem>
<MenuItem>Email</MenuItem>
</Menu>
</SubmenuTrigger>
</MenuButton>
<MenuTrigger>
<Button>Edit</Button>
<Menu {...args}>
<MenuItem>Favorite</MenuItem>
<MenuItem>Edit</MenuItem>
<MenuItem>Delete</MenuItem>
<SubmenuTrigger>
<MenuItem>Share</MenuItem>
<Menu>
<MenuItem>SMS</MenuItem>
<MenuItem>Email</MenuItem>
</Menu>
</SubmenuTrigger>
</Menu>
</MenuTrigger>
);

Example.args = {};
Loading
Loading