import type { False, True } from './bool.js'; import type { If } from './common.js'; import type { Assume, HKT1, HKT2, HKT3 } from './hkt.js'; import type { Int, Num } from './num/index.js'; export type Str = string; export declare namespace Str { export type Empty = ''; type Of = T extends string | number | bigint | boolean | null | undefined ? `${T}` : never; export interface Of$ extends HKT1 { new: (x: Assume) => Of; } export type Repeat = N extends 0 ? Empty : N extends 1 ? S : `${S}${Repeat>}`; export interface Repeat$ extends HKT1 { new: (s: Assume) => Repeat; } export type ToChars = S extends `${infer Head}${infer Tail}` ? readonly [Head, ...ToChars] : readonly []; export interface ToChars$ extends HKT1 { new: (s: Assume) => ToChars; } export type IsDigit = S extends `${infer C}` ? C extends '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' ? True : False : False; export interface IsDigit$ extends HKT1 { new: (s: Assume) => IsDigit; } export type IfDigit = If, Then, Else>; export interface IfDigit$ extends HKT1 { new: (s: Assume) => IfDigit; } export interface IfDigit$$ extends HKT2 { new: ( s: Assume, then: Assume, ) => IfDigit; } export interface IfDigit$$$ extends HKT3 { new: ( s: Assume, then: Assume, else_: Assume, ) => IfDigit; } export {}; } //# sourceMappingURL=str.d.ts.map