{ dependentRollups.length === 1 ? __( - 'This will also delete 1 rollup that depends on it:', + 'This also deletes 1 rollup that uses it:', 'cortext' ) : sprintf( /* translators: %d: number of dependent rollup fields */ __( - 'This will also delete %d rollups that depend on it:', + 'This also deletes %d rollups that use it:', 'cortext' ), dependentRollups.length @@ -459,6 +505,26 @@ export default function FieldActionsMenu( { .join( ', ' ) }
) : null } + { dependentFormulas.length > 0 ? ( ++ { dependentFormulas.length === 1 + ? __( + 'This also deletes 1 formula that uses it:', + 'cortext' + ) + : sprintf( + /* translators: %d: number of dependent formula fields */ + __( + 'This also deletes %d formulas that use it:', + 'cortext' + ), + dependentFormulas.length + ) }{ ' ' } + { dependentFormulas + .map( ( candidate ) => candidate.label ) + .join( ', ' ) } +
+ ) : null } ) : null } { isEditingOptions && supportsOptions ? ( @@ -481,6 +547,38 @@ export default function FieldActionsMenu( { /> ) : null } + { isEditingFormula && supportsFormula ? ( +{ 'field("Name")' }
+
+ { 'dateBetween(now(), field("Created"), "days")' }
+
+ + { __( + 'Use single-value fields, formulas, and built-in fields. Multi-select, relation, and rollup fields are not available in v0.', + 'cortext' + ) } +
+{ code }
+ { text }
+