@almadar/ui 5.23.0 → 5.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/avl/index.cjs +2034 -1393
- package/dist/avl/index.js +968 -327
- package/dist/components/core/molecules/AssetPicker.d.ts +21 -0
- package/dist/components/core/molecules/CodeViewer.d.ts +3 -2
- package/dist/components/core/molecules/DocCodeBlock.d.ts +2 -1
- package/dist/components/core/molecules/GridPicker.d.ts +44 -0
- package/dist/components/core/molecules/IconPicker.d.ts +18 -0
- package/dist/components/core/molecules/PropertyInspector.d.ts +5 -2
- package/dist/components/core/molecules/RichBlockEditor.d.ts +7 -0
- package/dist/components/core/molecules/index.d.ts +6 -3
- package/dist/components/core/molecules/markdown/CodeBlock.d.ts +15 -1
- package/dist/components/core/molecules/markdown/index.d.ts +1 -1
- package/dist/components/core/organisms/index.d.ts +5 -5
- package/dist/components/core/templates/index.d.ts +1 -1
- package/dist/components/index.cjs +1588 -1192
- package/dist/components/index.js +687 -291
- package/dist/components/{core → marketing}/organisms/CaseStudyOrganism.d.ts +1 -1
- package/dist/components/{core → marketing}/organisms/FeatureGridOrganism.d.ts +1 -1
- package/dist/components/{core → marketing}/organisms/HeroOrganism.d.ts +1 -1
- package/dist/components/{core → marketing}/organisms/ShowcaseOrganism.d.ts +1 -1
- package/dist/components/{core → marketing}/organisms/StepFlowOrganism.d.ts +1 -1
- package/dist/docs/index.d.cts +20 -1
- package/dist/marketing/index.cjs +8 -5
- package/dist/marketing/index.d.ts +4 -4
- package/dist/marketing/index.js +8 -5
- package/dist/providers/index.cjs +1857 -1216
- package/dist/providers/index.js +942 -301
- package/dist/runtime/index.cjs +1897 -1256
- package/dist/runtime/index.js +946 -305
- package/package.json +2 -2
- /package/dist/components/{core → marketing}/molecules/MarketingFooter.d.ts +0 -0
- /package/dist/components/{core → marketing}/molecules/PullQuote.d.ts +0 -0
- /package/dist/components/{core → marketing}/templates/AuthLayout.d.ts +0 -0
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
*/
|
|
12
12
|
import React from 'react';
|
|
13
13
|
import type { EntityWith } from '@almadar/core';
|
|
14
|
-
import type { DisplayStateProps } from '
|
|
14
|
+
import type { DisplayStateProps } from '../../core/organisms/types';
|
|
15
15
|
export interface CaseStudyOrganismProps extends DisplayStateProps {
|
|
16
16
|
entity?: EntityWith<'title'> | readonly EntityWith<'title'>[];
|
|
17
17
|
heading?: string;
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
*/
|
|
12
12
|
import React from 'react';
|
|
13
13
|
import type { EntityWith } from '@almadar/core';
|
|
14
|
-
import type { DisplayStateProps } from '
|
|
14
|
+
import type { DisplayStateProps } from '../../core/organisms/types';
|
|
15
15
|
export interface FeatureGridOrganismProps extends DisplayStateProps {
|
|
16
16
|
entity?: EntityWith<'title'> | readonly EntityWith<'title'>[];
|
|
17
17
|
columns?: 2 | 3 | 4 | 6;
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
*/
|
|
12
12
|
import React from 'react';
|
|
13
13
|
import type { EntityWith } from '@almadar/core';
|
|
14
|
-
import type { DisplayStateProps } from '
|
|
14
|
+
import type { DisplayStateProps } from '../../core/organisms/types';
|
|
15
15
|
export interface HeroOrganismProps extends DisplayStateProps {
|
|
16
16
|
entity?: EntityWith<'title'>;
|
|
17
17
|
children?: React.ReactNode;
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
*/
|
|
12
12
|
import React from 'react';
|
|
13
13
|
import type { EntityWith } from '@almadar/core';
|
|
14
|
-
import type { DisplayStateProps } from '
|
|
14
|
+
import type { DisplayStateProps } from '../../core/organisms/types';
|
|
15
15
|
export interface ShowcaseOrganismProps extends DisplayStateProps {
|
|
16
16
|
entity?: EntityWith<'title'> | readonly EntityWith<'title'>[];
|
|
17
17
|
columns?: 2 | 3 | 4;
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
*/
|
|
11
11
|
import React from 'react';
|
|
12
12
|
import type { EntityWith } from '@almadar/core';
|
|
13
|
-
import type { DisplayStateProps } from '
|
|
13
|
+
import type { DisplayStateProps } from '../../core/organisms/types';
|
|
14
14
|
export interface StepFlowOrganismProps extends DisplayStateProps {
|
|
15
15
|
entity?: EntityWith<'title'> | readonly EntityWith<'title'>[];
|
|
16
16
|
orientation?: 'horizontal' | 'vertical';
|
package/dist/docs/index.d.cts
CHANGED
|
@@ -396,11 +396,30 @@ interface DocBreadcrumbProps {
|
|
|
396
396
|
}
|
|
397
397
|
declare const DocBreadcrumb: React.FC<DocBreadcrumbProps>;
|
|
398
398
|
|
|
399
|
+
/**
|
|
400
|
+
* CodeBlock Molecule Component
|
|
401
|
+
*
|
|
402
|
+
* A syntax-highlighted code block with copy-to-clipboard functionality.
|
|
403
|
+
* Preserves scroll position during re-renders.
|
|
404
|
+
*
|
|
405
|
+
* Event Contract:
|
|
406
|
+
* - Emits: UI:COPY_CODE { language, success }
|
|
407
|
+
*/
|
|
408
|
+
|
|
409
|
+
/**
|
|
410
|
+
* The set of languages with a registered PrismLight grammar (above) plus the
|
|
411
|
+
* `.orb`/`.lolo` grammars from `@almadar/syntax`. Authoritative: an unregistered
|
|
412
|
+
* value renders as plain text, so this union mirrors the `registerLanguage`
|
|
413
|
+
* calls exactly.
|
|
414
|
+
*/
|
|
415
|
+
declare const CODE_LANGUAGES: readonly ["text", "json", "javascript", "js", "typescript", "ts", "jsx", "tsx", "css", "markdown", "md", "bash", "shell", "sh", "yaml", "yml", "rust", "python", "py", "sql", "diff", "toml", "go", "graphql", "html", "xml", "orb", "lolo"];
|
|
416
|
+
type CodeLanguage = (typeof CODE_LANGUAGES)[number];
|
|
417
|
+
|
|
399
418
|
interface DocCodeBlockProps {
|
|
400
419
|
/** Code content to display */
|
|
401
420
|
code: string;
|
|
402
421
|
/** Programming language label */
|
|
403
|
-
language?:
|
|
422
|
+
language?: CodeLanguage;
|
|
404
423
|
/** Optional title/filename shown in the header bar */
|
|
405
424
|
title?: string;
|
|
406
425
|
/** Show line numbers in the gutter */
|
package/dist/marketing/index.cjs
CHANGED
|
@@ -5089,11 +5089,15 @@ var Avatar = ({
|
|
|
5089
5089
|
actionPayload
|
|
5090
5090
|
}) => {
|
|
5091
5091
|
const eventBus = useEventBus();
|
|
5092
|
+
const [imgFailed, setImgFailed] = React8__default.default.useState(false);
|
|
5093
|
+
React8__default.default.useEffect(() => {
|
|
5094
|
+
setImgFailed(false);
|
|
5095
|
+
}, [src]);
|
|
5092
5096
|
const initials = providedInitials ?? (name ? generateInitials(name) : void 0);
|
|
5093
5097
|
const IconComponent = typeof iconProp === "string" ? resolveIcon(iconProp) : iconProp;
|
|
5094
|
-
const hasImage = !!src;
|
|
5095
|
-
const hasInitials = !!initials;
|
|
5098
|
+
const hasImage = !!src && !imgFailed;
|
|
5096
5099
|
const hasIcon = !!IconComponent;
|
|
5100
|
+
const hasInitials = !!initials && !(hasIcon && !providedInitials);
|
|
5097
5101
|
const getInitialsBackground = () => "bg-primary text-primary-foreground";
|
|
5098
5102
|
const isClickable = action || onClick;
|
|
5099
5103
|
const handleClick = () => {
|
|
@@ -5123,9 +5127,8 @@ var Avatar = ({
|
|
|
5123
5127
|
src,
|
|
5124
5128
|
alt: alt || "Avatar",
|
|
5125
5129
|
className: "w-full h-full object-cover",
|
|
5126
|
-
onError: (
|
|
5127
|
-
|
|
5128
|
-
target.style.display = "none";
|
|
5130
|
+
onError: () => {
|
|
5131
|
+
setImgFailed(true);
|
|
5129
5132
|
}
|
|
5130
5133
|
}
|
|
5131
5134
|
) : hasInitials ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -52,12 +52,12 @@ export type { CaseStudyCardProps } from '../components/marketing/molecules/CaseS
|
|
|
52
52
|
export { ArticleSection } from '../components/marketing/molecules/ArticleSection';
|
|
53
53
|
export type { ArticleSectionProps } from '../components/marketing/molecules/ArticleSection';
|
|
54
54
|
export { SimpleGrid } from '../components/core/molecules/SimpleGrid';
|
|
55
|
-
export { MarketingFooter } from '../components/
|
|
56
|
-
export type { MarketingFooterProps, FooterLinkColumn, FooterLinkItem } from '../components/
|
|
55
|
+
export { MarketingFooter } from '../components/marketing/molecules/MarketingFooter';
|
|
56
|
+
export type { MarketingFooterProps, FooterLinkColumn, FooterLinkItem } from '../components/marketing/molecules/MarketingFooter';
|
|
57
57
|
export { GradientDivider } from '../components/core/molecules/GradientDivider';
|
|
58
58
|
export type { GradientDividerProps } from '../components/core/molecules/GradientDivider';
|
|
59
|
-
export { PullQuote } from '../components/
|
|
60
|
-
export type { PullQuoteProps } from '../components/
|
|
59
|
+
export { PullQuote } from '../components/marketing/molecules/PullQuote';
|
|
60
|
+
export type { PullQuoteProps } from '../components/marketing/molecules/PullQuote';
|
|
61
61
|
export { AnimatedCounter } from '../components/core/molecules/AnimatedCounter';
|
|
62
62
|
export type { AnimatedCounterProps } from '../components/core/molecules/AnimatedCounter';
|
|
63
63
|
export { AnimatedReveal } from '../components/marketing/atoms/AnimatedReveal';
|
package/dist/marketing/index.js
CHANGED
|
@@ -5062,11 +5062,15 @@ var Avatar = ({
|
|
|
5062
5062
|
actionPayload
|
|
5063
5063
|
}) => {
|
|
5064
5064
|
const eventBus = useEventBus();
|
|
5065
|
+
const [imgFailed, setImgFailed] = React8.useState(false);
|
|
5066
|
+
React8.useEffect(() => {
|
|
5067
|
+
setImgFailed(false);
|
|
5068
|
+
}, [src]);
|
|
5065
5069
|
const initials = providedInitials ?? (name ? generateInitials(name) : void 0);
|
|
5066
5070
|
const IconComponent = typeof iconProp === "string" ? resolveIcon(iconProp) : iconProp;
|
|
5067
|
-
const hasImage = !!src;
|
|
5068
|
-
const hasInitials = !!initials;
|
|
5071
|
+
const hasImage = !!src && !imgFailed;
|
|
5069
5072
|
const hasIcon = !!IconComponent;
|
|
5073
|
+
const hasInitials = !!initials && !(hasIcon && !providedInitials);
|
|
5070
5074
|
const getInitialsBackground = () => "bg-primary text-primary-foreground";
|
|
5071
5075
|
const isClickable = action || onClick;
|
|
5072
5076
|
const handleClick = () => {
|
|
@@ -5096,9 +5100,8 @@ var Avatar = ({
|
|
|
5096
5100
|
src,
|
|
5097
5101
|
alt: alt || "Avatar",
|
|
5098
5102
|
className: "w-full h-full object-cover",
|
|
5099
|
-
onError: (
|
|
5100
|
-
|
|
5101
|
-
target.style.display = "none";
|
|
5103
|
+
onError: () => {
|
|
5104
|
+
setImgFailed(true);
|
|
5102
5105
|
}
|
|
5103
5106
|
}
|
|
5104
5107
|
) : hasInitials ? /* @__PURE__ */ jsx(
|