import type { NzSafeAny } from 'ng-zorro-antd/core/types' ; declare const ngDevMode ; const record = { } ; export const PREFIX = '[@DELON]:' ; function notRecorded ( ... args ) { const asRecord = args . reduce ( ( acc , c ) => acc + c . toString ( ) , '' ) ; if ( record [ asRecord ] ) { return false ; } else { record [ asRecord ] = true ; return true ; } } function consoleCommonBehavior ( consoleFunc , ... args ) { if ( ( typeof ngDevMode === 'undefined' || ngDevMode ) && notRecorded ( ... args ) ) { consoleFunc ( ... args ) ; } } export const warn = ( ... args ) : void => consoleCommonBehavior ( ( ... arg ) => console . warn ( PREFIX , ... arg ) , ... args ) ; export const warnDeprecation = ( ... args ) : NzSafeAny => { if ( typeof ngDevMode === 'undefined' || ngDevMode ) { return ( ) => { } ; } const stack = new Error ( ) . stack ; return consoleCommonBehavior ( ( ... arg ) => console . warn ( PREFIX , 'deprecated:' , ... arg , stack ) , ... args ) ; } ; export const log = ( ... args ) : void => { if ( typeof ngDevMode === 'undefined' || ngDevMode ) { console . log ( PREFIX , ... args ) ; } } ;