@joshfarrant/shortcuts-js
Version:
An iOS 12 Shortcuts creator
26 lines • 739 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
const utils_1 = require("../utils");
/**
* @action Match Text
* @section Content Types > Text > Text Editing
* @icon Text
*
* Searches text passed into the action for matches to a regular expression.
*
* ```js
* matchText({
* pattern: '[0-9a-zA-Z]',
* caseSensitive: false,
* });
* ```
*/
const matchText = ({ pattern = '', caseSensitive = false, }) => ({
WFWorkflowActionIdentifier: 'is.workflow.actions.text.match',
WFWorkflowActionParameters: {
WFMatchTextPattern: pattern,
WFMatchTextCaseSensitive: caseSensitive,
},
});
exports.default = utils_1.withActionOutput(matchText);
//# sourceMappingURL=matchText.js.map