import { DateTime, RecurrenceRuleResult, RuleOption } from '@rschedule/core'; import '../ByDayOfWeek/types'; import { IFrequencyRuleOptions, INormFrequencyRuleOptions } from '../Frequency'; import { RecurrenceRuleBase } from '../utilities/recurrence-rule-base'; import './types'; declare module '../../recurrence-rule-options' { interface IRuleOptions extends IByDayOfMonthRuleOptions {} interface INormRuleOptions extends INormByDayOfMonthRuleOptions {} } export interface IByDayOfMonthRuleOptions extends IFrequencyRuleOptions { byDayOfMonth?: RuleOption.ByDayOfMonth[]; } export interface INormByDayOfMonthRuleOptions extends INormFrequencyRuleOptions { byDayOfMonth?: RuleOption.ByDayOfMonth[]; byDayOfWeek?: RuleOption.ByDayOfWeek[]; } export declare class ByDayOfMonthRule extends RecurrenceRuleBase< INormByDayOfMonthRuleOptions > { run(date: DateTime): RecurrenceRuleResult; } /** * Does a few things: * * 1. filters out byDayOfMonth entries which are not applicable * to current month * 2. negative entries to positive ones * 3. if a byDayOfWeek option is given, removes days which are * not on the correct day of the week */ export declare function normalizeByDayOfMonth( date: DateTime, byDayOfMonth: RuleOption.ByDayOfMonth[], byDayOfWeek?: RuleOption.ByDayOfWeek[], ): number[];