Skip to content

Commit

Permalink
ci(changesets): version packages (alpha) (#1967)
Browse files Browse the repository at this point in the history
This PR was opened by the [Changesets
release](https://github.com/changesets/action) GitHub action. When
you're ready to do a release, you can merge this and the packages will
be published to npm automatically. If you're not ready to do a release
yet, that's fine, whenever you add more changesets to alpha, this PR
will be updated.

⚠️⚠️⚠️⚠️⚠️⚠️

`alpha` is currently in **pre mode** so this branch has prereleases
rather than normal releases. If you want to exit prereleases, run
`changeset pre exit` on `alpha`.

⚠️⚠️⚠️⚠️⚠️⚠️

# Releases
## @channel.io/[email protected]

### Major Changes

- **Breaking Changes: Remove `TooltipProvider` and Property updates in
`Tooltip` component**
([#1974](#1974)) by
@sungik-choi

- No longer support `TooltipProvider` and `TooltipProviderProps`.
`Tooltip` component was implemented via radix-ui's Tooltip, which
required the use of a `TooltipProvider`, which caused all subcomponents
to be re-rendered and caused a performance hit. We decided that the
ability to share hover delay time between `Tooltip` components via
`TooltipProvider` was not a feature we needed, even with the performance
penalty. Also, by providing `TooltipProvider` built-in to `AppProvider`,
we were unnecessarily importing modules from our library usage that
didn't require `Tooltip`.
    -   `Tooltip` component now contains a `TooltipProvider` inside it.

    **Minor Changes:**

    -   Change the default value of `delayShow` prop from `300` to `0`.

- **Breaking changes: Remove `testId` and related properties**
([#1971](#1971)) by
@sungik-choi

No longer supports `testId` and related properties(e.g.
`wrapperTestId`). `testId` is a property used internally by the library
for testing with testing-library (`getByTestId`). We don't see a need to
expose this as a public API, so we remove it.

If you were using it, please replace it with the `data-testid` property.
See <https://testing-library.com/docs/queries/bytestid/>.

- **Breaking Changes: Deprecated modules for internal use**
([#1963](#1963)) by
@sungik-choi

    -   No longer provides `useEventHandler` and `useMergeRefs` hook.
- No longer provides `useId` hook. Use `useId` hook of `react` instead.
- No longer provides `getRootElement` hook. Use `useWindow` hook
instead.
    -   No longer provides `StyleUtils` and `StringUtils` utils.

- **Breaking Changes: Deprecate support for `styled-components` related
modules**
([#1962](#1962)) by
@sungik-choi

- No longer support legacy foundation modules. Use the `useToken` hook
and components to replace it
        -   `LightFoundation` and `DarkFoundation`
        -   `Spacing`
        -   `ev1`, `ev2`, `ev3`, `ev4`, `ev5` and `ev6`
- `createThemes`, `Theme`, `SemanticNames`, `LightTheme` and `DarkTheme`
        -   `TransitionDuration` and `Transition`
        -   `Border`
- `Typography`, `TypoAbsoluteNumber`, `LineHeightAbsoluteNumber` and
`TypographyType`
- `absoluteCenter`, `disableAutoMinimum`, `hideScrollbars` and
`ellipsis`
        -   `ThemeVarsAdditionalType` and `ThemeVars`
        -   `GlobalStyle`
        -   `Foundation`
        -   `GlobalStyleProp`
- `createGlobalStyle`, `styled`, `css`, `FoundationProvider`,
`useFoundation`, `keyframes`, `StyleSheetManager` and `ServerStyleSheet`
- No longer support `BezierProvider`. Use the `AppProvider` instead
- No longer support `gap` and `touchableHover` mixins. Please implement
and use your own

    ```tsx
    function gap(spacing: number): InjectedInterpolation {
      return css`
        gap: ${spacing}px;

        @supports not (gap: ${spacing}px) {
          margin-top: ${-spacing}px;
          margin-left: ${-spacing}px;

          > * {
            margin-top: ${spacing}px;
            margin-left: ${spacing}px;
          }
        }
      `;
    }

    function touchableHover(
      interpolation: InjectedInterpolation
    ): InjectedInterpolation {
      return css`
        @media (hover: hover) {
          &:hover {
            ${interpolation}
          }
        }

        @media (hover: none) {
          &:active {
            ${interpolation}
          }
        }
      `;
    }
    ```

- No longer support `inputTextStyle`, `inputPlaceholderStyle`,
`inputWrapperStyle`, `focusedInputWrapperStyle` and
`erroredInputWrapperStyle`. Please migrate using
`@channel.io/bezier-codemod`'s `v2-interpolation-to-css-variable`
transformer.

### Minor Changes

- `Banner` will now render content even if the `content` prop is not a
string. The same applies to link-related props.
([#1972](#1972)) by
@sungik-choi

- Add `useRootElement` hook. It is only available to `WindowProvider`
children, and provides easy access to the root element of window context
value. ([#1981](#1981))
by @sungik-choi

    ```tsx
    const { window, document, rootElement } = useWindow();
    // Same as useWindow().rootElement
    const rootElement = useRootElement();
    ```

### Patch Changes

- Fixes a bug where onHide is called when clicking inside the overlay,
causing the overlay to close.
([#1977](#1977)) by
@yangwooseong

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
  • Loading branch information
github-actions[bot] and github-actions[bot] authored Feb 7, 2024
1 parent 2a373cc commit 6472068
Show file tree
Hide file tree
Showing 3 changed files with 107 additions and 1 deletion.
7 changes: 7 additions & 0 deletions .changeset/pre.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
"cuddly-chairs-warn",
"cuddly-crews-matter",
"curly-poets-decide",
"curvy-dragons-rest",
"cyan-pumpkins-run",
"dry-schools-draw",
"early-garlics-smoke",
Expand All @@ -29,6 +30,7 @@
"funny-peaches-report",
"gentle-shirts-grow",
"good-dodos-obey",
"great-ties-hunt",
"healthy-rocks-tap",
"healthy-waves-promise",
"hip-students-care",
Expand All @@ -39,6 +41,7 @@
"large-pants-brush",
"large-wasps-compete",
"little-bikes-obey",
"long-birds-attend",
"long-turtles-enjoy",
"loud-feet-melt",
"metal-planets-peel",
Expand All @@ -62,11 +65,13 @@
"silent-falcons-behave",
"silver-pets-hammer",
"six-lemons-admire",
"sixty-cows-fetch",
"slimy-lobsters-sparkle",
"small-readers-compare",
"soft-months-film",
"sour-dogs-sin",
"stale-nails-study",
"strange-colts-beg",
"strange-toes-tap",
"sweet-cups-tell",
"sweet-kangaroos-rush",
Expand All @@ -85,6 +90,8 @@
"weak-toys-dress",
"wicked-months-sparkle",
"wild-cows-rescue",
"wild-walls-suffer",
"witty-kids-tie",
"witty-pans-clean",
"yellow-eagles-matter"
]
Expand Down
99 changes: 99 additions & 0 deletions packages/bezier-react/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,104 @@
# @channel.io/bezier-react

## 2.0.0-alpha.10

### Major Changes

- **Breaking Changes: Remove `TooltipProvider` and Property updates in `Tooltip` component** ([#1974](https://github.com/channel-io/bezier-react/pull/1974)) by @sungik-choi

- No longer support `TooltipProvider` and `TooltipProviderProps`. `Tooltip` component was implemented via radix-ui's Tooltip, which required the use of a `TooltipProvider`, which caused all subcomponents to be re-rendered and caused a performance hit. We decided that the ability to share hover delay time between `Tooltip` components via `TooltipProvider` was not a feature we needed, even with the performance penalty. Also, by providing `TooltipProvider` built-in to `AppProvider`, we were unnecessarily importing modules from our library usage that didn't require `Tooltip`.
- `Tooltip` component now contains a `TooltipProvider` inside it.

**Minor Changes:**

- Change the default value of `delayShow` prop from `300` to `0`.

- **Breaking changes: Remove `testId` and related properties** ([#1971](https://github.com/channel-io/bezier-react/pull/1971)) by @sungik-choi

No longer supports `testId` and related properties(e.g. `wrapperTestId`). `testId` is a property used internally by the library for testing with testing-library (`getByTestId`). We don't see a need to expose this as a public API, so we remove it.

If you were using it, please replace it with the `data-testid` property. See <https://testing-library.com/docs/queries/bytestid/>.

- **Breaking Changes: Deprecated modules for internal use** ([#1963](https://github.com/channel-io/bezier-react/pull/1963)) by @sungik-choi

- No longer provides `useEventHandler` and `useMergeRefs` hook.
- No longer provides `useId` hook. Use `useId` hook of `react` instead.
- No longer provides `getRootElement` hook. Use `useWindow` hook instead.
- No longer provides `StyleUtils` and `StringUtils` utils.

- **Breaking Changes: Deprecate support for `styled-components` related modules** ([#1962](https://github.com/channel-io/bezier-react/pull/1962)) by @sungik-choi

- No longer support legacy foundation modules. Use the `useToken` hook and components to replace it
- `LightFoundation` and `DarkFoundation`
- `Spacing`
- `ev1`, `ev2`, `ev3`, `ev4`, `ev5` and `ev6`
- `createThemes`, `Theme`, `SemanticNames`, `LightTheme` and `DarkTheme`
- `TransitionDuration` and `Transition`
- `Border`
- `Typography`, `TypoAbsoluteNumber`, `LineHeightAbsoluteNumber` and `TypographyType`
- `absoluteCenter`, `disableAutoMinimum`, `hideScrollbars` and `ellipsis`
- `ThemeVarsAdditionalType` and `ThemeVars`
- `GlobalStyle`
- `Foundation`
- `GlobalStyleProp`
- `createGlobalStyle`, `styled`, `css`, `FoundationProvider`, `useFoundation`, `keyframes`, `StyleSheetManager` and `ServerStyleSheet`
- No longer support `BezierProvider`. Use the `AppProvider` instead
- No longer support `gap` and `touchableHover` mixins. Please implement and use your own

```tsx
function gap(spacing: number): InjectedInterpolation {
return css`
gap: ${spacing}px;

@supports not (gap: ${spacing}px) {
margin-top: ${-spacing}px;
margin-left: ${-spacing}px;

> * {
margin-top: ${spacing}px;
margin-left: ${spacing}px;
}
}
`;
}

function touchableHover(
interpolation: InjectedInterpolation
): InjectedInterpolation {
return css`
@media (hover: hover) {
&:hover {
${interpolation}
}
}

@media (hover: none) {
&:active {
${interpolation}
}
}
`;
}
```

- No longer support `inputTextStyle`, `inputPlaceholderStyle`, `inputWrapperStyle`, `focusedInputWrapperStyle` and `erroredInputWrapperStyle`. Please migrate using `@channel.io/bezier-codemod`'s `v2-interpolation-to-css-variable` transformer.

### Minor Changes

- `Banner` will now render content even if the `content` prop is not a string. The same applies to link-related props. ([#1972](https://github.com/channel-io/bezier-react/pull/1972)) by @sungik-choi

- Add `useRootElement` hook. It is only available to `WindowProvider` children, and provides easy access to the root element of window context value. ([#1981](https://github.com/channel-io/bezier-react/pull/1981)) by @sungik-choi

```tsx
const { window, document, rootElement } = useWindow();
// Same as useWindow().rootElement
const rootElement = useRootElement();
```

### Patch Changes

- Fixes a bug where onHide is called when clicking inside the overlay, causing the overlay to close. ([#1977](https://github.com/channel-io/bezier-react/pull/1977)) by @yangwooseong

## 2.0.0-alpha.9

### Major Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/bezier-react/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@channel.io/bezier-react",
"version": "2.0.0-alpha.9",
"version": "2.0.0-alpha.10",
"description": "React components library that implements Bezier design system.",
"repository": {
"type": "git",
Expand Down

0 comments on commit 6472068

Please sign in to comment.