@kensingtontech/ngx-highlightjs
Advanced tools
Comparing version 11.0.0-beta1.0 to 11.4.0
/** | ||
* Generated bundle index. Do not edit. | ||
*/ | ||
/// <amd-module name="@kensingtontech/ngx-highlightjs" /> | ||
export * from './public-api'; |
@@ -5,2 +5,3 @@ import { OnChanges, SimpleChanges, EventEmitter, ElementRef } from '@angular/core'; | ||
import { NgxHighlightOptions, HighlightResult } from './highlight.model'; | ||
import * as i0 from "@angular/core"; | ||
export declare class HighlightDirective implements OnChanges { | ||
@@ -29,2 +30,4 @@ private _highlightService; | ||
private setInnerHTML; | ||
static ɵfac: i0.ɵɵFactoryDeclaration<HighlightDirective, [null, null, null, { optional: true; }]>; | ||
static ɵdir: i0.ɵɵDirectiveDeclaration<HighlightDirective, "[highlight]", never, { "code": "highlight"; "languages": "languages"; "lineNumbers": "lineNumbers"; }, { "highlighted": "highlighted"; }, never>; | ||
} |
import { Observable } from 'rxjs'; | ||
import { NgxHighlightOptions } from './highlight.model'; | ||
import { HLJSApi } from 'highlight.js'; | ||
import * as i0 from "@angular/core"; | ||
export declare class HighlightLoader { | ||
@@ -29,2 +30,4 @@ private _options; | ||
private loadLineNumbers; | ||
static ɵfac: i0.ɵɵFactoryDeclaration<HighlightLoader, [null, null, { optional: true; }]>; | ||
static ɵprov: i0.ɵɵInjectableDeclaration<HighlightLoader>; | ||
} |
@@ -0,2 +1,7 @@ | ||
import * as i0 from "@angular/core"; | ||
import * as i1 from "./highlight.directive"; | ||
export declare class HighlightModule { | ||
static ɵfac: i0.ɵɵFactoryDeclaration<HighlightModule, never>; | ||
static ɵmod: i0.ɵɵNgModuleDeclaration<HighlightModule, [typeof i1.HighlightDirective], never, [typeof i1.HighlightDirective]>; | ||
static ɵinj: i0.ɵɵInjectorDeclaration<HighlightModule>; | ||
} |
@@ -5,3 +5,4 @@ import { Observable } from 'rxjs'; | ||
import { HLJSApi } from 'highlight.js'; | ||
import { Mode, HighlightOptions } from 'highlight.js'; | ||
import { HighlightOptions } from 'highlight.js'; | ||
import * as i0 from "@angular/core"; | ||
export declare class HighlightService { | ||
@@ -18,6 +19,4 @@ private _loader; | ||
* even in case of detecting illegal syntax for the language instead of throwing an exception. | ||
* @param continuation An optional mode stack representing unfinished parsing. | ||
* When present, the function will restart parsing from this state instead of initializing a new one | ||
*/ | ||
highlight(codeOrLanguageName: string, optionsOrCode: string | HighlightOptions, ignoreIllegals?: boolean, continuation?: Mode): Observable<HighlightResult>; | ||
highlight(codeOrLanguageName: string, optionsOrCode: string | HighlightOptions, ignoreIllegals?: boolean): Observable<HighlightResult>; | ||
/** | ||
@@ -68,2 +67,4 @@ * Highlighting with language detection. | ||
lineNumbersBlock(el: HTMLElement): Observable<any>; | ||
static ɵfac: i0.ɵɵFactoryDeclaration<HighlightService, [null, { optional: true; }]>; | ||
static ɵprov: i0.ɵɵInjectableDeclaration<HighlightService>; | ||
} |
{ | ||
"name": "@kensingtontech/ngx-highlightjs", | ||
"version": "11.0.0-beta1.0", | ||
"version": "11.4.0", | ||
"description": "Instant code highlighting, auto-detect language", | ||
@@ -28,16 +28,36 @@ "homepage": "https://github.com/KensingtonTech/ngx-highlightjs", | ||
"peerDependencies": { | ||
"@angular/common": ">=8.0.0", | ||
"@angular/core": ">=8.0.0", | ||
"@angular/common": ">=13.0.0", | ||
"@angular/core": ">=13.0.0", | ||
"rxjs": ">=6.0.0", | ||
"highlight.js": "^11.0.0-beta1", | ||
"highlightjs-line-numbers.js": "*" | ||
"highlight.js": "~11.4.0", | ||
"highlightjs-line-numbers.js": "^2.8.0" | ||
}, | ||
"main": "bundles/kensingtontech-ngx-highlightjs.umd.js", | ||
"module": "fesm2015/kensingtontech-ngx-highlightjs.js", | ||
"es2015": "fesm2015/kensingtontech-ngx-highlightjs.js", | ||
"esm2015": "esm2015/kensingtontech-ngx-highlightjs.js", | ||
"fesm2015": "fesm2015/kensingtontech-ngx-highlightjs.js", | ||
"module": "fesm2015/kensingtontech-ngx-highlightjs.mjs", | ||
"es2020": "fesm2020/kensingtontech-ngx-highlightjs.mjs", | ||
"esm2020": "esm2020/kensingtontech-ngx-highlightjs.mjs", | ||
"fesm2020": "fesm2020/kensingtontech-ngx-highlightjs.mjs", | ||
"fesm2015": "fesm2015/kensingtontech-ngx-highlightjs.mjs", | ||
"typings": "kensingtontech-ngx-highlightjs.d.ts", | ||
"metadata": "kensingtontech-ngx-highlightjs.metadata.json", | ||
"exports": { | ||
"./package.json": { | ||
"default": "./package.json" | ||
}, | ||
".": { | ||
"types": "./kensingtontech-ngx-highlightjs.d.ts", | ||
"esm2020": "./esm2020/kensingtontech-ngx-highlightjs.mjs", | ||
"es2020": "./fesm2020/kensingtontech-ngx-highlightjs.mjs", | ||
"es2015": "./fesm2015/kensingtontech-ngx-highlightjs.mjs", | ||
"node": "./fesm2015/kensingtontech-ngx-highlightjs.mjs", | ||
"default": "./fesm2020/kensingtontech-ngx-highlightjs.mjs" | ||
}, | ||
"./plus": { | ||
"types": "./plus/kensingtontech-ngx-highlightjs-plus.d.ts", | ||
"esm2020": "./esm2020/plus/kensingtontech-ngx-highlightjs-plus.mjs", | ||
"es2020": "./fesm2020/kensingtontech-ngx-highlightjs-plus.mjs", | ||
"es2015": "./fesm2015/kensingtontech-ngx-highlightjs-plus.mjs", | ||
"node": "./fesm2015/kensingtontech-ngx-highlightjs-plus.mjs", | ||
"default": "./fesm2020/kensingtontech-ngx-highlightjs-plus.mjs" | ||
} | ||
}, | ||
"sideEffects": false | ||
} |
import { PipeTransform } from '@angular/core'; | ||
import { Observable } from 'rxjs'; | ||
import { CodeLoader } from './code-loader'; | ||
import * as i0 from "@angular/core"; | ||
export declare class CodeFromUrlPipe implements PipeTransform { | ||
@@ -8,2 +9,4 @@ private _loader; | ||
transform(url: string): Observable<string>; | ||
static ɵfac: i0.ɵɵFactoryDeclaration<CodeFromUrlPipe, never>; | ||
static ɵpipe: i0.ɵɵPipeDeclaration<CodeFromUrlPipe, "codeFromUrl">; | ||
} |
import { HttpClient } from '@angular/common/http'; | ||
import { Observable } from 'rxjs'; | ||
import { Gist, GistOptions } from './gist.model'; | ||
import * as i0 from "@angular/core"; | ||
export declare class CodeLoader { | ||
@@ -23,2 +24,4 @@ private _http; | ||
private fetchFile; | ||
static ɵfac: i0.ɵɵFactoryDeclaration<CodeLoader, [null, { optional: true; }]>; | ||
static ɵprov: i0.ɵɵInjectableDeclaration<CodeLoader>; | ||
} |
import { PipeTransform, EventEmitter } from '@angular/core'; | ||
import { CodeLoader } from './code-loader'; | ||
import { Gist } from './gist.model'; | ||
import * as i0 from "@angular/core"; | ||
export declare class GistDirective { | ||
@@ -9,5 +10,9 @@ private _loader; | ||
gistLoad: EventEmitter<Gist>; | ||
static ɵfac: i0.ɵɵFactoryDeclaration<GistDirective, never>; | ||
static ɵdir: i0.ɵɵDirectiveDeclaration<GistDirective, "[gist]", never, { "gist": "gist"; }, { "gistLoad": "gistLoad"; }, never>; | ||
} | ||
export declare class GistFilePipe implements PipeTransform { | ||
transform(gist: Gist, fileName: string): string | null; | ||
static ɵfac: i0.ɵɵFactoryDeclaration<GistFilePipe, never>; | ||
static ɵpipe: i0.ɵɵPipeDeclaration<GistFilePipe, "gistFile">; | ||
} |
@@ -0,2 +1,10 @@ | ||
import * as i0 from "@angular/core"; | ||
import * as i1 from "./gist"; | ||
import * as i2 from "./code-from-url"; | ||
import * as i3 from "@kensingtontech/ngx-highlightjs"; | ||
import * as i4 from "@angular/common/http"; | ||
export declare class HighlightPlusModule { | ||
static ɵfac: i0.ɵɵFactoryDeclaration<HighlightPlusModule, never>; | ||
static ɵmod: i0.ɵɵNgModuleDeclaration<HighlightPlusModule, [typeof i1.GistDirective, typeof i1.GistFilePipe, typeof i2.CodeFromUrlPipe], [typeof i3.HighlightModule, typeof i4.HttpClientModule], [typeof i3.HighlightModule, typeof i1.GistDirective, typeof i1.GistFilePipe, typeof i2.CodeFromUrlPipe]>; | ||
static ɵinj: i0.ɵɵInjectorDeclaration<HighlightPlusModule>; | ||
} |
/** | ||
* Generated bundle index. Do not edit. | ||
*/ | ||
/// <amd-module name="@kensingtontech/ngx-highlightjs/plus" /> | ||
export * from './public_api'; |
{ | ||
"main": "../bundles/kensingtontech-ngx-highlightjs-plus.umd.js", | ||
"module": "../fesm2015/kensingtontech-ngx-highlightjs-plus.js", | ||
"es2015": "../fesm2015/kensingtontech-ngx-highlightjs-plus.js", | ||
"esm2015": "../esm2015/plus/kensingtontech-ngx-highlightjs-plus.js", | ||
"fesm2015": "../fesm2015/kensingtontech-ngx-highlightjs-plus.js", | ||
"module": "../fesm2015/kensingtontech-ngx-highlightjs-plus.mjs", | ||
"es2020": "../fesm2020/kensingtontech-ngx-highlightjs-plus.mjs", | ||
"esm2020": "../esm2020/plus/kensingtontech-ngx-highlightjs-plus.mjs", | ||
"fesm2020": "../fesm2020/kensingtontech-ngx-highlightjs-plus.mjs", | ||
"fesm2015": "../fesm2015/kensingtontech-ngx-highlightjs-plus.mjs", | ||
"typings": "kensingtontech-ngx-highlightjs-plus.d.ts", | ||
"metadata": "kensingtontech-ngx-highlightjs-plus.metadata.json", | ||
"sideEffects": false, | ||
"name": "@kensingtontech/ngx-highlightjs/plus" | ||
} |
@@ -6,4 +6,5 @@ # Angular Highlight.js | ||
## Differences from the original | ||
- Uses highlight.js@^11.0.0-beta1. | ||
- Suppors ESM module imports. | ||
- Uses highlight.js@11.4.0. | ||
- Built with and requires Angular@^13.0.0. | ||
- Supports ESM module imports. | ||
- Renamed some files for more intuitive usage. | ||
@@ -10,0 +11,0 @@ - Removed HighlightLibrary interface in favour of highlight.js' own Typescript definition |
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
312007
0
258
42
2340
1