/*
THIS IS A GENERATED/BUNDLED FILE BY ESBUILD
if you want to view the source, please visit the github repository of this plugin
*/

(function initCjs() {
  // eslint-disable-next-line obsidianmd/no-global-this -- Actively use globalThis.
  const globalThisRecord = globalThis;
  globalThisRecord['__name'] ??= name;
  const originalRequire = require;
  if (originalRequire && !originalRequire.__isPatched) {
    // eslint-disable-next-line no-global-assign, no-implicit-globals -- We need to patch the `require()` function.
    require = Object.assign(
      (id) => requirePatched(id),
      originalRequire,
      {
        __isPatched: true
      }
    );
  }

  const newFuncs = {
    __extractDefault() {
      return extractDefault;
    },
    process() {
      const browserProcess = {
        browser: true,
        cwd() {
          return '/';
        },
        env: {},
        platform: 'android'
      };
      return browserProcess;
    }
  };

  for (const key of Object.keys(newFuncs)) {
    globalThisRecord[key] ??= newFuncs[key]?.();
  }

  function name(obj) {
    return obj;
  }

  function extractDefault(module) {
    return module && module.__esModule && 'default' in module ? module.default : module;
  }

  const OBSIDIAN_BUILT_IN_MODULE_NAMES = [
  'obsidian',
  '@codemirror/autocomplete',
  '@codemirror/collab',
  '@codemirror/commands',
  '@codemirror/language',
  '@codemirror/lint',
  '@codemirror/search',
  '@codemirror/state',
  '@codemirror/text',
  '@codemirror/view',
  '@lezer/common',
  '@lezer/lr',
  '@lezer/highlight'];


  const DEPRECATED_OBSIDIAN_BUILT_IN_MODULE_NAMES = [
  '@codemirror/closebrackets',
  '@codemirror/comment',
  '@codemirror/fold',
  '@codemirror/gutter',
  '@codemirror/highlight',
  '@codemirror/history',
  '@codemirror/matchbrackets',
  '@codemirror/panel',
  '@codemirror/rangeset',
  '@codemirror/rectangular-selection',
  '@codemirror/stream-parser',
  '@codemirror/tooltip'];


  function requirePatched(id) {
    if (OBSIDIAN_BUILT_IN_MODULE_NAMES.includes(id) || DEPRECATED_OBSIDIAN_BUILT_IN_MODULE_NAMES.includes(id)) {
      return originalRequire?.(id);
    }

    // eslint-disable-next-line @typescript-eslint/no-deprecated, obsidianmd/no-global-this  -- Need access to app. Actively use globalThis.
    if (globalThis.app.isMobile) {
      if (id === 'process' || id === 'node:process') {
        // eslint-disable-next-line no-console -- Valid usage.
        console.debug(`The most likely you can safely ignore this error. Module not found: ${id}. Fake process object is returned instead.`);
        // eslint-disable-next-line obsidianmd/no-global-this -- Actively use globalThis.
        return globalThis.process;
      }
    } else {
      const module = originalRequire?.(id);
      if (module) {
        return extractDefault(module);
      }
    }

    // eslint-disable-next-line no-console -- Valid usage.
    console.debug(`The most likely you can safely ignore this error. Module not found: ${id}. Empty object is returned instead.`);
    return {};
  }
})();

"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
  for (var name in all)
    __defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
  if (from && typeof from === "object" || typeof from === "function") {
    for (let key of __getOwnPropNames(from))
      if (!__hasOwnProp.call(to, key) && key !== except)
        __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
  }
  return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
var readonly_params_options_members_exports = {};
__export(readonly_params_options_members_exports, {
  MESSAGE_ID: () => MESSAGE_ID,
  readonlyParamsOptionsMembers: () => readonlyParamsOptionsMembers
});
module.exports = __toCommonJS(readonly_params_options_members_exports);
var import_type_guards = require('../../../type-guards.cjs');
const MESSAGE_ID = "readonlyParamsOptionsMembers";
const readonlyParamsOptionsMembers = {
  create(context) {
    return {
      "TSInterfaceDeclaration[id.name=/(?:Params|Options)$/] TSPropertySignature[readonly=false]"(node) {
        reportNonReadonly(context, node);
      },
      "TSTypeAliasDeclaration[id.name=/(?:Params|Options)$/] TSPropertySignature[readonly=false]"(node) {
        reportNonReadonly(context, node);
      }
    };
    function reportNonReadonly(ctx, node) {
      const propertyNode = node;
      ctx.report({
        fix(fixer) {
          return fixer.insertTextBefore((0, import_type_guards.ensureNonNullable)(propertyNode.key), "readonly ");
        },
        messageId: MESSAGE_ID,
        node
      });
    }
  },
  meta: {
    docs: {
      description: "Require all properties in `*Params` and `*Options` interfaces to be `readonly`"
    },
    fixable: "code",
    messages: {
      [MESSAGE_ID]: "Property must be `readonly`. Params/Options interfaces should be immutable."
    },
    schema: [],
    type: "suggestion"
  }
};
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
  MESSAGE_ID,
  readonlyParamsOptionsMembers
});
//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsiLi4vLi4vLi4vLi4vLi4vLi4vc3JjL3NjcmlwdC11dGlscy9saW50ZXJzL2VzbGludC1ydWxlcy9yZWFkb25seS1wYXJhbXMtb3B0aW9ucy1tZW1iZXJzLnRzIl0sCiAgInNvdXJjZXNDb250ZW50IjogWyIvKipcbiAqIEBmaWxlXG4gKlxuICogRVNMaW50IHJ1bGU6IHJlYWRvbmx5LXBhcmFtcy1vcHRpb25zLW1lbWJlcnNcbiAqXG4gKiBSZXBvcnRzIGFuIGVycm9yIHdoZW4gYW4gaW50ZXJmYWNlIG9yIHR5cGUgYWxpYXMgd2hvc2UgbmFtZSBlbmRzIHdpdGhcbiAqIGBQYXJhbXNgIG9yIGBPcHRpb25zYCBoYXMgYSBwcm9wZXJ0eSBzaWduYXR1cmUgdGhhdCBpcyBub3QgYHJlYWRvbmx5YC5cbiAqIFBhcmFtZXRlci9vcHRpb25zIGJhZ3Mgc2hvdWxkIGJlIGltbXV0YWJsZSBcdTIwMTQgY2FsbGVycyBzaG91bGQgbmV2ZXIgbXV0YXRlXG4gKiB0aGUgb2JqZWN0IHRoZXkgcmVjZWl2ZWQuXG4gKi9cbmltcG9ydCB0eXBlIHsgUnVsZSB9IGZyb20gJ2VzbGludCc7XG5cbmltcG9ydCB7IGVuc3VyZU5vbk51bGxhYmxlIH0gZnJvbSAnLi4vLi4vLi4v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