{"version":3,"file":"typings.options.cjs","sources":["../../src/typings.options.ts"],"sourcesContent":["import type { JSONSchema4 } from \"@typescript-eslint/utils/json-schema\";\n\nexport type Options = {\n  /**\n   * specifies how the auto-fix wrapping mechanism functions.\n   *\n   * - \"overflow-only\" ensures that only overflowing lines are reflowed to new\n   * lines,\n   *\n   * - whereas \"compact\" tries to produce as compact blocks as possible,\n   * potentially merging multiple nearby lines even though no overflow was\n   * occuring on the lines.\n   *\n   * - Finally, \"compact-on-overflow\" attempts to produce as compact blocks as\n   * possible, however only when overflow within a block has been detected.\n   *\n   * @default overflow-only\n   */\n  mode: \"overflow-only\" | \"compact-on-overflow\" | \"compact\";\n\n  /**\n   * specifies the maxmium length that a comment is allowed to take\n   *\n   * @default 80\n   */\n  maxLength: number;\n\n  /**\n   * attempts to wrap at logical pauses in comments based on where punctuation\n   * is found.\n   *\n   * This will often wrap the text sooner than if this was disabled,\n   * but it potentially makes it easier to read comments.\n   *\n   * @default false\n   */\n  logicalWrap: boolean;\n\n  /**\n   * if set to true, then overflow lines including comments will be ignored\n   *\n   * @default true\n   */\n  ignoreUrls: boolean;\n\n  /**\n   * attempts to avoid reflowing comments that contains code as this may break\n   * the semantic meaning of the code.\n   *\n   * NB: This option causes ESLint to be run on comment content in an attempt\n   * to see if the code inside is parsable, which may have a significant\n   * performance impact depending on the parser used.\n   *\n   * @default false\n   */\n  ignoreCommentsWithCode: boolean;\n\n  /**\n   * in case you are using tabs to indent your code, then this plugin needs to\n   * know the configured tab size, in order to properly determine when a\n   * comment exceeds the configured max length.\n   *\n   * If you are using VSCode, then this option should match the\n   * `editor.tabSize` option.\n   *\n   * @default 2\n   */\n  tabSize: number;\n\n  /**\n   * by default semantic comments such as // eslint-disable* will be ignored by\n   * this plugin as they may alter the functionality of other programs.\n   *\n   * In case you need to add additional variants of comments that should be\n   * ignored by this plugin, then they can be added through this option.\n   *\n   * @example\n   * semanticComments: [\"i18n-extract-keys\", \"i18n-extract-mark-context\"]\n   */\n  semanticComments?: string[];\n};\n\nexport type RuleOptions = [Options];\n\nexport const defaultOptions = [\n  {\n    mode: \"overflow-only\",\n    maxLength: 80,\n    ignoreUrls: true,\n    ignoreCommentsWithCode: false,\n    tabSize: 2,\n    logicalWrap: false,\n    semanticComments: [],\n  },\n] satisfies RuleOptions;\n\nexport const optionsSchema = [\n  {\n    type: \"object\",\n    properties: {\n      mode: {\n        type: \"string\",\n        enum: [\"overflow-only\", \"compact-on-overflow\", \"compact\"],\n      },\n      maxLength: { type: \"integer\" },\n      ignoreUrls: { type: \"boolean\" },\n      ignoreCommentsWithCode: { type: \"boolean\" },\n      tabSize: { type: \"integer\" },\n      logicalWrap: { type: \"boolean\" },\n      semanticComments: {\n        type: \"array\",\n        items: { type: \"string\" },\n      },\n    },\n  },\n] satisfies [JSONSchema4];\n"],"names":[],"mappings":";;AAoFO,MAAM,cAAA,GAAiB;AAAA,EAC5B;AAAA,IACE,IAAA,EAAM,eAAA;AAAA,IACN,SAAA,EAAW,EAAA;AAAA,IACX,UAAA,EAAY,IAAA;AAAA,IACZ,sBAAA,EAAwB,KAAA;AAAA,IACxB,OAAA,EAAS,CAAA;AAAA,IACT,WAAA,EAAa,KAAA;AAAA,IACb,kBAAkB;AAAC;AAEvB;AAEO,MAAM,aAAA,GAAgB;AAAA,EAC3B;AAAA,IACE,IAAA,EAAM,QAAA;AAAA,IACN,UAAA,EAAY;AAAA,MACV,IAAA,EAAM;AAAA,QACJ,IAAA,EAAM,QAAA;AAAA,QACN,IAAA,EAAM,CAAC,eAAA,EAAiB,qBAAA,EAAuB,SAAS;AAAA,OAC1D;AAAA,MACA,SAAA,EAAW,EAAE,IAAA,EAAM,SAAA,EAAU;AAAA,MAC7B,UAAA,EAAY,EAAE,IAAA,EAAM,SAAA,EAAU;AAAA,MAC9B,sBAAA,EAAwB,EAAE,IAAA,EAAM,SAAA,EAAU;AAAA,MAC1C,OAAA,EAAS,EAAE,IAAA,EAAM,SAAA,EAAU;AAAA,MAC3B,WAAA,EAAa,EAAE,IAAA,EAAM,SAAA,EAAU;AAAA,MAC/B,gBAAA,EAAkB;AAAA,QAChB,IAAA,EAAM,OAAA;AAAA,QACN,KAAA,EAAO,EAAE,IAAA,EAAM,QAAA;AAAS;AAC1B;AACF;AAEJ;;;;;"}