@wordpress/block-library
Version:
Block library for the WordPress editor.
8 lines (7 loc) • 1.57 kB
Source Map (JSON)
{
"version": 3,
"sources": ["../../src/post-time-to-read/variations.js"],
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { timeToRead, wordCount } from '@wordpress/icons';\n\nconst variations = [\n\t{\n\t\tname: 'time-to-read',\n\t\ttitle: __( 'Time to Read' ),\n\t\tdescription: __( 'Show minutes required to finish reading the post.' ),\n\t\tattributes: {\n\t\t\tdisplayMode: 'time',\n\t\t},\n\t\tscope: [ 'inserter', 'transform' ],\n\t\tisActive: ( blockAttributes ) =>\n\t\t\tblockAttributes?.displayMode === 'time',\n\t\ticon: timeToRead,\n\t\tisDefault: true,\n\t},\n\t{\n\t\tname: 'word-count',\n\t\ttitle: __( 'Word Count' ),\n\t\tdescription: __( 'Show the number of words in the post.' ),\n\t\tattributes: {\n\t\t\tdisplayMode: 'words',\n\t\t},\n\t\tscope: [ 'inserter', 'transform' ],\n\t\tisActive: ( blockAttributes ) =>\n\t\t\tblockAttributes?.displayMode === 'words',\n\t\ticon: wordCount,\n\t},\n];\n\nexport default variations;\n"],
"mappings": ";AAGA,SAAS,UAAU;AACnB,SAAS,YAAY,iBAAiB;AAEtC,IAAM,aAAa;AAAA,EAClB;AAAA,IACC,MAAM;AAAA,IACN,OAAO,GAAI,cAAe;AAAA,IAC1B,aAAa,GAAI,mDAAoD;AAAA,IACrE,YAAY;AAAA,MACX,aAAa;AAAA,IACd;AAAA,IACA,OAAO,CAAE,YAAY,WAAY;AAAA,IACjC,UAAU,CAAE,oBACX,iBAAiB,gBAAgB;AAAA,IAClC,MAAM;AAAA,IACN,WAAW;AAAA,EACZ;AAAA,EACA;AAAA,IACC,MAAM;AAAA,IACN,OAAO,GAAI,YAAa;AAAA,IACxB,aAAa,GAAI,uCAAwC;AAAA,IACzD,YAAY;AAAA,MACX,aAAa;AAAA,IACd;AAAA,IACA,OAAO,CAAE,YAAY,WAAY;AAAA,IACjC,UAAU,CAAE,oBACX,iBAAiB,gBAAgB;AAAA,IAClC,MAAM;AAAA,EACP;AACD;AAEA,IAAO,qBAAQ;",
"names": []
}