@witchcraft/spellcraft
    Preparing search index...
    • Returns whether a chain is a subset of another, taking into account variants (this can be disabled).

      Parameters

      • chain: readonly string[][]
      • chainSubset: readonly string[][]
      • keys: Keys
      • __namedParameters: { allowVariants?: boolean; onlyPressable?: boolean; onlySubset?: boolean } = {}
        • OptionalallowVariants?: boolean
        • OptionalonlyPressable?: boolean

          If true, will return false if the shortcut is not one key press away.

        • OptionalonlySubset?: boolean

          If true, will return false if the last chord of the chainSubset is exactly equal.

          So for example, for the chain: [[a], [ctrl+b]], the following would return as follows:

          // true
          [[]] or []
          [[a]]
          [[a], []]
          [[a], [ctrl]]
          [[a], [b]]

          // false
          [[a], [ctrl, b]]

      Returns boolean