jxSpacingRules top-level constant

List<JxRuleContract> const jxSpacingRules

Spacing : p:, px:, py:, pt:, pr:, pb:, pl: et équivalents m*:. Les marges acceptent auto et les valeurs négatives.

Implementation

const List<JxRuleContract> jxSpacingRules = [
  JxValueRule(
    'padding',
    properties: {
      'p': ['padding'],
      'px': ['padding-left', 'padding-right'],
      'py': ['padding-top', 'padding-bottom'],
      'pt': ['padding-top'],
      'pr': ['padding-right'],
      'pb': ['padding-bottom'],
      'pl': ['padding-left'],
    },
    themeCategory: JxThemeCategory.spacing,
    disallowed: {'auto'},
  ),
  JxValueRule(
    'margin',
    properties: {
      'm': ['margin'],
      'mx': ['margin-left', 'margin-right'],
      'my': ['margin-top', 'margin-bottom'],
      'mt': ['margin-top'],
      'mr': ['margin-right'],
      'mb': ['margin-bottom'],
      'ml': ['margin-left'],
    },
    themeCategory: JxThemeCategory.spacing,
    allowNegative: true,
  ),
];