Skip to content

Commit

Permalink
change(listing): text align class names to better align to text utili…
Browse files Browse the repository at this point in the history
…ty class names
  • Loading branch information
ichim-david committed Nov 21, 2022
1 parent b22bc7d commit 1b09619
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/blocks/Listing/schema.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import alignLeftSVG from '@plone/volto/icons/align-left.svg';
import alignCenterSVG from '@plone/volto/icons/align-center.svg';

const ALIGN_INFO_MAP = {
align_left: [alignLeftSVG, 'Left'],
align_center: [alignCenterSVG, 'Center'],
left: [alignLeftSVG, 'Left'],
center: [alignCenterSVG, 'Center'],
};

// export const setBasicStylingSchema = (args) => {
Expand Down Expand Up @@ -234,7 +234,7 @@ export const setCardStylingSchema = ({ schema, intl }) => {
const itemModelSchema = schema.properties.itemModel;
const styleSchema = itemModelSchema.schema.properties.styles.schema;
const fieldset = styleSchema.fieldsets.find(({ id }) => id === 'default');
fieldset.fields.push('theme', 'inverted', 'rounded', 'text_align');
fieldset.fields.push('theme', 'inverted', 'rounded', 'text');
styleSchema.properties = {
...styleSchema.properties,
theme: {
Expand All @@ -257,7 +257,7 @@ export const setCardStylingSchema = ({ schema, intl }) => {
description: intl.formatMessage(messages.RoundedHelp),
type: 'boolean',
},
text_align: {
text: {
title: 'Text align',
widget: 'style_text_align',
actions: Object.keys(ALIGN_INFO_MAP),
Expand Down

0 comments on commit 1b09619

Please sign in to comment.