Skip to content

Commit 14f33a2

Browse files
committed
Also allow null directions
1 parent 5eb5b3f commit 14f33a2

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

data-model.d.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ export interface Literal {
7676
/**
7777
* the direction of the language-tagged string.
7878
*/
79-
direction?: 'ltr' | 'rtl' | '';
79+
direction?: 'ltr' | 'rtl' | '' | null;
8080
/**
8181
* A NamedNode whose IRI represents the datatype of the literal.
8282
*/
@@ -298,5 +298,5 @@ export interface DataFactory<OutQuad extends BaseQuad = Quad, InQuad extends Bas
298298

299299
export interface DirectionalLanguage {
300300
language: string;
301-
direction?: 'ltr' | 'rtl' | '';
301+
direction?: 'ltr' | 'rtl' | '' | null;
302302
}

rdf-js-tests.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ function test_terms() {
3636
const termType3: string = literal.termType;
3737
const value3: string = literal.value;
3838
const language3: string = literal.language;
39-
const dir3: 'ltr' | 'rtl' | '' | undefined = literal.direction;
39+
const dir3: 'ltr' | 'rtl' | '' | null | undefined = literal.direction;
4040
const datatype3: NamedNode = literal.datatype;
4141
let literalEqual: boolean = literal.equals(someTerm);
4242
literalEqual = literal.equals(null);

0 commit comments

Comments
 (0)