Skip to content

Commit

Permalink
Updates
Browse files Browse the repository at this point in the history
  • Loading branch information
actions-user committed Nov 11, 2024
1 parent 2c649b0 commit 4cecda9
Show file tree
Hide file tree
Showing 15 changed files with 8,442 additions and 8,434 deletions.
40 changes: 21 additions & 19 deletions Notice.d.ts
Original file line number Diff line number Diff line change
@@ -1,30 +1,32 @@
import React, { type ReactNode, type CSSProperties } from "react";
export type NoticeProps = {
id?: string;
className?: string;
classes?: Partial<Record<"root" | "title" | "close", string>>;
title: NonNullable<ReactNode>;
style?: CSSProperties;
} & (NoticeProps.NonClosable | NoticeProps.Closable);
export type NoticeProps = NoticeProps.NonClosable | NoticeProps.Closable;
export declare namespace NoticeProps {
type NonClosable = {
type Common = {
id?: string;
className?: string;
classes?: Partial<Record<"root" | "title" | "close", string>>;
title: NonNullable<ReactNode>;
style?: CSSProperties;
};
export type NonClosable = Common & {
isClosable?: false;
isClosed?: undefined;
onClose?: undefined;
isClosed?: never;
onClose?: never;
};
type Closable = {
isClosable: true;
} & (Closable.Controlled | Closable.Uncontrolled);
namespace Closable {
type Controlled = {
export type Closable = Closable.Controlled | Closable.Uncontrolled;
export namespace Closable {
type Controlled = Common & {
isClosable: true;
isClosed: boolean;
onClose: () => void;
onClose: (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => void;
};
type Uncontrolled = {
isClosed?: undefined;
onClose?: () => void;
type Uncontrolled = Common & {
isClosable: true;
onClose?: (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => void;
isClosed?: never;
};
}
export {};
}
/** @see <https://components.react-dsfr.codegouv.studio/?path=/docs/components-notice> */
export declare const Notice: React.MemoExoticComponent<React.ForwardRefExoticComponent<NoticeProps & React.RefAttributes<HTMLDivElement>>>;
Expand Down
10 changes: 5 additions & 5 deletions Notice.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Notice.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 4cecda9

Please sign in to comment.