mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
Merge e707279c37
into a5d6939826
This commit is contained in:
commit
b7d3ce0c79
3 changed files with 11 additions and 2 deletions
|
@ -326,7 +326,7 @@ export const actionChangeStrokeColor = register({
|
||||||
<>
|
<>
|
||||||
<h3 aria-hidden="true">{t("labels.stroke")}</h3>
|
<h3 aria-hidden="true">{t("labels.stroke")}</h3>
|
||||||
<ColorPicker
|
<ColorPicker
|
||||||
topPicks={DEFAULT_ELEMENT_STROKE_PICKS}
|
topPicks={appProps.strokeColorTopPicks ?? DEFAULT_ELEMENT_STROKE_PICKS}
|
||||||
palette={DEFAULT_ELEMENT_STROKE_COLOR_PALETTE}
|
palette={DEFAULT_ELEMENT_STROKE_COLOR_PALETTE}
|
||||||
type="elementStroke"
|
type="elementStroke"
|
||||||
label={t("labels.stroke")}
|
label={t("labels.stroke")}
|
||||||
|
@ -372,7 +372,9 @@ export const actionChangeBackgroundColor = register({
|
||||||
<>
|
<>
|
||||||
<h3 aria-hidden="true">{t("labels.background")}</h3>
|
<h3 aria-hidden="true">{t("labels.background")}</h3>
|
||||||
<ColorPicker
|
<ColorPicker
|
||||||
topPicks={DEFAULT_ELEMENT_BACKGROUND_PICKS}
|
topPicks={
|
||||||
|
appProps.backgroundColorTopPicks ?? DEFAULT_ELEMENT_BACKGROUND_PICKS
|
||||||
|
}
|
||||||
palette={DEFAULT_ELEMENT_BACKGROUND_COLOR_PALETTE}
|
palette={DEFAULT_ELEMENT_BACKGROUND_COLOR_PALETTE}
|
||||||
type="elementBackground"
|
type="elementBackground"
|
||||||
label={t("labels.background")}
|
label={t("labels.background")}
|
||||||
|
|
|
@ -53,6 +53,8 @@ const ExcalidrawBase = (props: ExcalidrawProps) => {
|
||||||
renderEmbeddable,
|
renderEmbeddable,
|
||||||
aiEnabled,
|
aiEnabled,
|
||||||
showDeprecatedFonts,
|
showDeprecatedFonts,
|
||||||
|
strokeColorTopPicks,
|
||||||
|
backgroundColorTopPicks,
|
||||||
} = props;
|
} = props;
|
||||||
|
|
||||||
const canvasActions = props.UIOptions?.canvasActions;
|
const canvasActions = props.UIOptions?.canvasActions;
|
||||||
|
@ -143,6 +145,8 @@ const ExcalidrawBase = (props: ExcalidrawProps) => {
|
||||||
renderEmbeddable={renderEmbeddable}
|
renderEmbeddable={renderEmbeddable}
|
||||||
aiEnabled={aiEnabled !== false}
|
aiEnabled={aiEnabled !== false}
|
||||||
showDeprecatedFonts={showDeprecatedFonts}
|
showDeprecatedFonts={showDeprecatedFonts}
|
||||||
|
strokeColorTopPicks={strokeColorTopPicks}
|
||||||
|
backgroundColorTopPicks={backgroundColorTopPicks}
|
||||||
>
|
>
|
||||||
{children}
|
{children}
|
||||||
</App>
|
</App>
|
||||||
|
|
|
@ -3,6 +3,7 @@ import type {
|
||||||
UserIdleState,
|
UserIdleState,
|
||||||
throttleRAF,
|
throttleRAF,
|
||||||
MIME_TYPES,
|
MIME_TYPES,
|
||||||
|
ColorTuple,
|
||||||
} from "@excalidraw/common";
|
} from "@excalidraw/common";
|
||||||
|
|
||||||
import type { SuggestedBinding } from "@excalidraw/element/binding";
|
import type { SuggestedBinding } from "@excalidraw/element/binding";
|
||||||
|
@ -601,6 +602,8 @@ export interface ExcalidrawProps {
|
||||||
) => JSX.Element | null;
|
) => JSX.Element | null;
|
||||||
aiEnabled?: boolean;
|
aiEnabled?: boolean;
|
||||||
showDeprecatedFonts?: boolean;
|
showDeprecatedFonts?: boolean;
|
||||||
|
strokeColorTopPicks?: ColorTuple;
|
||||||
|
backgroundColorTopPicks?: ColorTuple;
|
||||||
}
|
}
|
||||||
|
|
||||||
export type SceneData = {
|
export type SceneData = {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue