Skip to content

Releases: vivid-planet/comet

6.18.0

10 Jan 11:43
5583c9c
Compare
Choose a tag to compare

@comet/cms-admin@6.18.0

Minor Changes

  • ed126f8: Validate filename length for uploads to DAM or FileUploads

    The filename can't exceed 255 characters.

@comet/cms-api@6.18.0

Minor Changes

  • ed126f8: Validate filename length for uploads to DAM or FileUploads

    The filename can't exceed 255 characters.

5.10.0

10 Jan 11:37
5583c9c
Compare
Choose a tag to compare

@comet/cms-admin@5.10.0

Minor Changes

  • 453f0c4: Validate filename length for uploads to DAM or FileUploads

    The filename can't exceed 255 characters.

@comet/cms-api@5.10.0

Minor Changes

  • 453f0c4: Validate filename length for uploads to DAM or FileUploads

    The filename can't exceed 255 characters.

7.11.0

08 Jan 08:20
578437c
Compare
Choose a tag to compare

@comet/admin@7.11.0

Minor Changes

  • b8b8e27: Make GridFilterButton and GridColumnsButton responsive by moving their text to a tooltip on mobile

    • This also makes the button's styles consistent with the standard Button component
    • GridFilterButton now supports props to override the default button props
  • e9f547d: Adjust how tooltips are triggered

    This is to achieve a more consistent and user-friendly experience by ensuring tooltips are always shown when the user interacts with the underlying element.

    • When using the default hover trigger, tooltips will now be shown on both hover and focus. Previously, you had to choose between hover and focus.
    • The trigger prop is deprecated and will be removed in a future major version. The combined hover/focus trigger will be the only supported behavior.
    • Tooltips on touch devices will be shown immediately when the user starts interacting with the underlying element.

Patch Changes

  • 1e01cca: Prevent scrolling of DialogTitle and DialogActions in EditDialog

  • a30f0ee: Fix border-color of InputBase on default and hover state

  • 20f6341: Prevent the page content from overflowing the window, causing a horizontal scrollbar

    This happened when using elements like Tabs that are intended to be horizontally scrollable and could, therefore, be wider than the window.

  • 8114a6a: Fix onClick and other props not being passed to the icon version of some button components

@comet/admin-theme@7.11.0

Minor Changes

  • a4fcdeb: Enable vertical resizing for TextAreaField and other multiline inputs

  • 5ba64aa: Add support and styling for full screen dialogs using the fullScreen prop

    <Dialog open fullScreen>
        <DialogTitle>Dialog Title</DialogTitle>
        <DialogContent>Dialog content</DialogContent>
    </Dialog>

Patch Changes

  • 9f2a127: Fix an issue where setting defaultProps of MuiDataGrid would override the defaultProps defined by createCometTheme()
  • a30f0ee: Fix border-color of InputBase on default and hover state

@comet/cms-admin@7.11.0

Minor Changes

  • 3acbb04: Update design of the user menu in the header and add information about the impersonated user

Patch Changes

  • 94cc411: Adapt styling of ContentScopeSelect to match the Comet design
  • 6778c4e: Prevent the creation of a second home page
  • 7992a9a: Enable setting importSourceId and importSourceType for each individual file in the useDamFileUpload#uploadFiles function

@comet/blocks-api@7.11.0

Patch Changes

  • 58a99bb: Fix input validation for missing child blocks

@comet/cms-api@7.11.0

Patch Changes

  • fb2297b: Fix notEqual operation for enum filter
  • 6778c4e: Prevent the creation of a second home page

6.17.17

19 Dec 09:55
6778c4e
Compare
Choose a tag to compare

@comet/blocks-api@6.17.17

Patch Changes

  • 8ef35ec: Fix input validation for missing child blocks

5.9.6

19 Dec 09:54
6778c4e
Compare
Choose a tag to compare

@comet/blocks-api@5.9.6

Patch Changes

  • 31029dc: Fix input validation for missing child blocks

7.10.0

10 Dec 11:49
4c3259f
Compare
Choose a tag to compare

@comet/admin@7.10.0

Minor Changes

  • 8f924d5: Add new custom Dialog

    The component extends the MUI Dialog component to enable common use cases:

    • The title prop can be used to set the dialog title
    • A close button is shown when the onClose is used

    Example

    <Dialog
        title="Dialog Title"
        onClose={() => {
            // Handle dialog closing here
        }}
    />
  • 6eba5ab: Add a forceVerticalContainerSize prop to FieldContainer

    Use it to define below which container size the vertical styling is applied when using the horizontal variant.

  • 589b0b9: Enhance FieldContainer with secondaryHelperText prop and helperTextIcon prop

    • helperTextIcon displays an icon alongside the text for helperText, error or warning.
    • secondaryHelperText provides an additional helper text positioned beneath the input field, aligned to the bottom-right corner.

    Example:

    <FieldContainer label="Helper Text Icon" helperTextIcon={<Info />} helperText="Helper Text with icon" secondaryHelperText="0/100">
        <InputBase onChange={handleChange} value={value} placeholder="Placeholder" />
    </FieldContainer>

Patch Changes

  • aa02ca1: Fix a bug in useDataGridExcelExport that would cause an Excel export to fail when a cell's value was undefined
  • 6eba5ab: Prevent unintended layout shift after the initial render of FieldContainer when using the horizontal variant
  • bf6b03f: Fix alignment of Alert icon with the title

@comet/admin-theme@7.10.0

Minor Changes

  • 7e94c55: Rework GridFilterPanel to match the updated Comet CI

  • 22f3d40: Adapt Chip styling to align with Comet DXP design

    • Fix hover styling
    • Add new styling for <Chip variant="filled" color="info">
  • 589b0b9: Enhance FieldContainer with secondaryHelperText prop and helperTextIcon prop

    • helperTextIcon displays an icon alongside the text for helperText, error or warning.
    • secondaryHelperText provides an additional helper text positioned beneath the input field, aligned to the bottom-right corner.

    Example:

    <FieldContainer label="Helper Text Icon" helperTextIcon={<Info />} helperText="Helper Text with icon" secondaryHelperText="0/100">
        <InputBase onChange={handleChange} value={value} placeholder="Placeholder" />
    </FieldContainer>

Patch Changes

  • b51bf6d: Adapt Radio and Checkbox styling to Comet DXP design

    Fix colors of disabled states.

  • 71876ea: Adapt size of arrow in Select and Autocomplete fields according to Comet DXP design

@comet/cms-admin@7.10.0

Minor Changes

  • 2b9fac2: Add support for passing title and alt text to useDamFileUpload

    This can be useful when importing files from an external DAM.

Patch Changes

  • d210ef7: Remove vertical and horizontal scroll bars from block preview iframe

@comet/cms-api@7.10.0

Patch Changes

  • 7b2adae: API Generator: Don't generate an update input for the single generator

7.9.0

04 Dec 12:03
7ddea88
Compare
Choose a tag to compare

@comet/admin@7.9.0

Minor Changes

  • 6d6131b: Add the dataGridDateColumn and dataGridDateTimeColumn helpers for using the "date" and "dateTime" types in Data Grid

    -import { GridColDef } from "@comet/admin";
    +import { GridColDef, dataGridDateColumn, dataGridDateTimeColumn } from "@comet/admin";
    
     // ...
    
     const columns: GridColDef[] = [
         {
    -       type: "date",
    -       valueGetter: ({ value }) => value && new Date(value),
    -       renderCell: ({ value }) => value && <FormattedDate value={value} dateStyle="medium" />,
    +       ...dataGridDateColumn,
            field: "createdAt",
            headerName: "Created At",
         },
         {
    -      type: "dateTime",
    -      valueGetter: ({ value }) => value && new Date(value),
    -      renderCell: ({ value }) => value && <FormattedDate value={value} dateStyle="medium" timeStyle="short" />,
    +      ...dataGridDateTimeColumn,
           field: "updatedAt",
           headerName: "Updated At",
         },
     ];
  • 7cea765: Add UI for Impersonation Feature

    • Add indicator to display when impersonation mode is active in UserHeaderItem
    • Add button to allow users to switch on impersonation in the UserGrid
    • Integrate CrudMoreActionsMenu in UserPageToolbar with an impersonation entry for easy access to this feature.
    • Add ImpersonateUser icon

Patch Changes

  • 48cac4d: Fix styling issues of inputs like FinalFormInput, FinalFormNumberInput, FinalFormSelect, TextAreaField

    • Change background-color, border-color and color of the label for different states (default, disabled and focused).
    • For required inputs, fix spacing between the label and asterisk.
    • Fix font-weight and margin of helperText.
  • 0919e3b: Remove right padding from form fields without an end adornment

@comet/admin-color-picker@7.9.0

Patch Changes

  • 1d73f3f: Add missing spacing to the clear-color button of ColorPicker

@comet/admin-icons@7.9.0

Minor Changes

  • 7cea765: Add UI for Impersonation Feature

    • Add indicator to display when impersonation mode is active in UserHeaderItem
    • Add button to allow users to switch on impersonation in the UserGrid
    • Integrate CrudMoreActionsMenu in UserPageToolbar with an impersonation entry for easy access to this feature.
    • Add ImpersonateUser icon

Patch Changes

  • 55d40ef: Add icon for indeterminate checkbox

@comet/admin-theme@7.9.0

Minor Changes

  • 9aa6947: Add hover styling for MUI's Switch

Patch Changes

  • 48cac4d: Fix styling issues of inputs like FinalFormInput, FinalFormNumberInput, FinalFormSelect, TextAreaField

    • Change background-color, border-color and color of the label for different states (default, disabled and focused).
    • For required inputs, fix spacing between the label and asterisk.
    • Fix font-weight and margin of helperText.
  • 55d40ef: Add icon for indeterminate checkbox

@comet/blocks-admin@7.9.0

Minor Changes

  • 92f9d07: Add hiddenForState option to createCompositeBlock

    This function can be used to hide a block in the AdminComponent for a given state.

    Example

    const TextWithMediaVariantBlock = createCompositeBlock({
        name: "TextWithMediaVariant",
        blocks: {
            variant: {
                block: createCompositeBlockSelectField<string>({
                    defaultValue: "text-image",
                    fieldProps: { label: "Variant", fullWidth: true },
                    options: [
                        { value: "text-image", label: "Text Image" },
                        { value: "text-only", label: "Text Only" },
                    ],
                }),
            },
            text: {
                block: RichTextBlock,
            },
            media: {
                block: MediaBlock,
                // The media block isn't needed for the "text-only" variant
                hiddenForState: (state) => state.variant === "text-only",
            },
        },
    });
  • 047b9d1: Add label prop to ColumnsLayoutPreview

    Use it to customize the label of the column displayed in the FinalFormLayoutSelect.
    For instance, to add an icon or add custom text:

    <ColumnsLayoutPreviewContent width={10} label={<Image />} />
  • 59b4b6f: Add visibleOrderedBlocksForState option to createCompositeBlock

    The option can be used to hide and order child blocks in the AdminComponent.
    It should return an array of visible block keys for a given state.
    The order of the keys define the order in which the blocks will be rendered.
    If key is not present in the array, the block will not be rendered.

    Example

    const LayoutBlock = createCompositeBlock({
        /* ... */
        blocks: {
            layout: {
                /* A layout select */
            },
            headline1: { block: HeadlineBlock },
            image1: { block: DamImageBlock },
            headline2: { block: HeadlineBlock },
            image2: { block: DamImageBlock },
        },
        visibleOrderedBlocksForState: (state: LayoutBlockData) => {
            if (state.layout === "compact") {
                // headline2 and image2 will be hidden
                return ["headline1", "image1"];
            } else {
                return ["headline1", "image1", "headline2", "image2"];
            }
        },
    });

@comet/cms-admin@7.9.0

Minor Changes

  • 7cea765: Add UI for Impersonation Feature

    • Add indicator to display when impersonation mode is active in UserHeaderItem
    • Add button to allow users to switch on impersonation in the UserGrid
    • Integrate CrudMoreActionsMenu in UserPageToolbar with an impersonation entry for easy access to this feature.
    • Add ImpersonateUser icon

Patch Changes

  • 6d6131b: Use consistent date and time formatting across the Admin UI
  • 27510c2: Prevent ContentScopeIndicator from crashing when a scope part is undefined
  • 8ed5795: Don't add non-existing scope parts to the DamScope as undefined
  • 7ce4b0f: Fix DAM license duration input when no values are provided

7.8.0

27 Nov 10:21
2ae7216
Compare
Choose a tag to compare

@comet/admin@7.8.0

Minor Changes

  • 139616b: Add FullHeightContent component

    Used to help components take advantage of all the available content height, e.g., when using a DataGrid inside Tabs already contained in a MainContent component.

    Usage example for FullHeightContent:

    <MainContent>
        <RouterTabs>
            <RouterTab label="DataGrid Example" path="">
                <FullHeightContent>
                    <DataGrid />
                </FullHeightContent>
            </RouterTab>
            <RouterTab label="Another tab" path="/another-tab">
                Content of another tab
            </RouterTab>
        </RouterTabs>
    </MainContent>

    Example where MainContent with fullHeight should be used, instead of FullHeightContent:

    <MainContent fullHeight>
        <DataGrid />
    </MainContent>
  • d8fca05: Add second InitialFormValues generic to FinalForm

    This allows differentiating between a form's values and initial values.

  • d8298d5: Add the StackMainContent component

    This version of MainContent only adds content spacing and height when it's the last visible StackSwitch.
    Using StackMainContent instead of MainContent prevents unintended or duplicate spacings in cases where multiple MainContent components are used inside nested StackSwitch components.

Patch Changes

  • a168e55: Open collapsible menu item on refresh if its child or sub-child is selected

  • e16ad1a: Fix a bug that prevented dynamically rendered tabs in Tabs

  • 139616b: Fix the fullHeight behavior of MainContent

    When used inside certain elements, e.g. with position: relative, the height would be calculated incorrectly.

  • eefb054: Render empty values correctly when using renderStaticSelectCell as a DataGrid column's renderCell function

  • 795ec73: Fix the spacing between the text and chip in CrudMoreActionsMenu

  • 8617c3b: Fix URL prefix in SubRouteIndexRoute

  • daacf1e: Fix a bug in ToolbarBreadcrumbs where it was possible to open the mobile breadcrumbs menu when there were no items to be shown in the menu

  • 9cc75c1: Prevent the width of the mobile breadcrumbs menu of ToolbarBreadcrumbs from being far too small

@comet/admin-icons@7.8.0

Minor Changes

  • e78315c: Add ContactPage icon
  • c6d3ac3: Add new icons Backward and Forward

@comet/blocks-admin@7.8.0

Minor Changes

  • 059636a: Pass the graphQLApiUrl for useBlockPreviewFetch through the IFrameBridge

    It's not necessary to set it in the site anymore. To migrate, remove the argument from useBlockPreviewFetch():

    const PreviewPage = () => {
        const iFrameBridge = useIFrameBridge();
    
    -   const { fetch, graphQLFetch } = useBlockPreviewFetch(graphQLApiUrl);
    +   const { fetch, graphQLFetch } = useBlockPreviewFetch();
    
        const [blockData, setBlockData] = useState<PageContentBlockData>();
        useEffect(() => {
            async function load() {
    +           if (!graphQLFetch) {
    +               return;
    +           }
                if (!iFrameBridge.block) {
                    setBlockData(undefined);
                    return;
                }
                const newData = await recursivelyLoadBlockData({
                    blockType: "PageContent",
                    blockData: iFrameBridge.block,
                    graphQLFetch,
                    fetch,
                    pageTreeNodeId: undefined, //we don't have a pageTreeNodeId in preview
                });
                setBlockData(newData);
            }
            load();
        }, [iFrameBridge.block, fetch, graphQLFetch]);
    
        return <div>{blockData && <PageContentBlock data={blockData} />}</div>;
    };

Patch Changes

  • 4338a6c: Make the space select required in the form when using createSpaceBlock()

@comet/cms-admin@7.8.0

Minor Changes

  • 44a5455: Allow replacing a file with a new one on the file detail page in the DAM

  • b721ac0: Harmonize the size and alignment of the DAM filters

  • c6d3ac3: Add support for file replacement on upload in the DAM

    When uploading a file to the DAM with the same filename as an existing file, it's now possible to replace the existing file.
    This is useful when you want to update a file without changing its URL.

  • 4037b4d: Rework the DAM crop/focus settings UI

  • 059636a: Pass the graphQLApiUrl for useBlockPreviewFetch through the IFrameBridge

    It's not necessary to set it in the site anymore. To migrate, remove the argument from useBlockPreviewFetch():

    const PreviewPage = () => {
        const iFrameBridge = useIFrameBridge();
    
    -   const { fetch, graphQLFetch } = useBlockPreviewFetch(graphQLApiUrl);
    +   const { fetch, graphQLFetch } = useBlockPreviewFetch();
    
        const [blockData, setBlockData] = useState<PageContentBlockData>();
        useEffect(() => {
            async function load() {
    +           if (!graphQLFetch) {
    +               return;
    +           }
                if (!iFrameBridge.block) {
                    setBlockData(undefined);
                    return;
                }
                const newData = await recursivelyLoadBlockData({
                    blockType: "PageContent",
                    blockData: iFrameBridge.block,
                    graphQLFetch,
                    fetch,
                    pageTreeNodeId: undefined, //we don't have a pageTreeNodeId in preview
                });
                setBlockData(newData);
            }
            load();
        }, [iFrameBridge.block, fetch, graphQLFetch]);
    
        return <div>{blockData && <PageContentBlock data={blockData} />}</div>;
    };

Patch Changes

  • bfa5dba: Fix schema generation if FileUpload object type isn't used

    Previously, the file uploads module always added the downloadUrl and imageUrl fields to the FileUpload object type, even if the type wasn't used in the application.
    This lead to errors when generating the GraphQL schema.

    Now, the fields are only added if the download option of the module is used.

    Note: As a consequence, the finalFormFileUploadFragment doesn't include the fields anymore.
    To enable downloading file uploads in forms, use the newly added finalFormFileUploadDownloadableFragment:

    export const productFormFragment = gql`
        fragment ProductFormFragment on Product {
            priceList {
    -           ...FinalFormFileUpload
    +           ...FinalFormFileUploadDownloadable
            }
        }
    
    -   ${finalFormFileUploadFragment}
    +   ${finalFormFileUploadDownloadableFragment}
    `;
  • 62ead06: Master Menu: render collapsible or grouped menu items only when at least one item of the submenu is allowed.

@comet/blocks-api@7.8.0

Patch Changes

  • f20ec6c: Make class-validator a peer dependency

@comet/cms-api@7.8.0

Minor Changes

  • 44a5455: Allow replacing a file with a new one on the file detail page in the DAM

  • 45fbc54: Rename User to UserPermissionsUser in GraphQL schema

    This prevents naming collisions if a web wants to use a User type.

    Additionally prefix remaining user permissions-specific actions with UserPermissions.

  • c6d3ac3: Add support for file replacement on upload in the DAM

    When uploading a file to the DAM with the same filename as an existing file, it's now possible to replace the existing file.
    This is useful when you want to update a file without changing its URL.

Patch Changes

  • bfa5dba: Fix schema generation if FileUpload object type isn't used

    Previously, the file uploads module always added the downloadUrl and imageUrl fields to the FileUpload object type, even if the type wasn't used in the application.
    This lead to errors when generating the GraphQL schema.

    Now, the fields are only added if the download option of the module is used.

    Note: As a consequence, the finalFormFileUploadFragment doesn't include the fields anymore.
    To enable downloading file uploads in forms, use the newly added finalFormFileUploadDownloadableFragment:

    export const productFormFragment = gql`
        fragment ProductFormFragment on Product {
            priceList {
    -           ...FinalFormFileUpload
    +           ...FinalFormFileUploadDownloadable
            }
        }
    
    -   ${finalFormFileUploadFragment}
    +   ${finalFormFileUploadDownloadableFragment}
    `;
  • 02a5bdc: API Generator: Fix generated types for position code

  • f20ec6c: Make class-validator a peer dependency

@comet/cms-site@7.8.0

Minor Changes

  • 2352959: Export convertPreviewDataToHeaders to make createGraphQLFetch more configurable

  • 059636a: Pass the graphQLApiUrl for useBlockPreviewFetch through the IFrameBridge

    It's not necessary to set it in the site anymore. To migrate, remove the argument from useBlockPreviewFetch():

    const PreviewPage = () => {
        const iFrameBridge = useIFrameBridge();
    
    -   const { fetch, graphQLFetch } = useBlockPreviewFetch(graphQLApiUrl);
    +   const { fetch, graphQLFetch } = useBlockPreviewFetch();
    
        const [blockData, setBlockData] = useState<PageContentBlockData>();
        useEffect(() => {
            async function load() {
    +           if (!graphQLFetch) {
    +               return;
    +           }
                if (!iFrameBridge.block) {
                    ...
Read more

6.17.16

25 Nov 08:50
6f4ca29
Compare
Choose a tag to compare

@comet/cms-api@6.17.16

Patch Changes

  • ee5b5ae: DAM: Fix/set cache-control headers

    • Public endpoints should cache files for 1 day
    • Private endpoints should cache files for 1 year - but only in local caches (not CDN)

5.9.5

21 Nov 13:32
4037b4d
Compare
Choose a tag to compare

@comet/cms-api@5.9.5

Patch Changes

  • ec67253: DAM: Fix/set cache-control headers

    • Public endpoints should cache files for 1 day
    • Private endpoints should cache files for 1 year - but only in local caches (not CDN)