Imports now specify the file extension to support Node v12

This commit is contained in:
n1474335 2019-07-09 12:23:59 +01:00
parent d7d50337f9
commit 566517d20f
469 changed files with 1098 additions and 1093 deletions

View file

@ -5,7 +5,7 @@
* @license Apache-2.0
*/
import Utils from "../Utils";
import Utils from "../Utils.mjs";
import BigNumber from "bignumber.js";

View file

@ -6,7 +6,7 @@
* @license Apache-2.0
*/
import Utils from "../Utils";
import Utils from "../Utils.mjs";
/**

View file

@ -6,7 +6,7 @@
* @license Apache-2.0
*/
import Utils from "../Utils";
import Utils from "../Utils.mjs";
/**

View file

@ -7,9 +7,9 @@
* @license Apache-2.0
*/
import OperationError from "../errors/OperationError";
import Utils from "../Utils";
import {Rotor, Plugboard, a2i, i2a} from "./Enigma";
import OperationError from "../errors/OperationError.mjs";
import Utils from "../Utils.mjs";
import {Rotor, Plugboard, a2i, i2a} from "./Enigma.mjs";
/**
* Convenience/optimisation subclass of Rotor

View file

@ -5,7 +5,7 @@
* @license Apache-2.0
*/
import OperationError from "../errors/OperationError";
import OperationError from "../errors/OperationError.mjs";
/**
* @constant

View file

@ -9,7 +9,7 @@
*
*/
import OperationError from "../errors/OperationError";
import OperationError from "../errors/OperationError.mjs";
import CryptoJS from "crypto-js";
/**

View file

@ -8,7 +8,7 @@
import geohash from "ngeohash";
import geodesy from "geodesy";
import OperationError from "../errors/OperationError";
import OperationError from "../errors/OperationError.mjs";
/**
* Co-ordinate formats

View file

@ -6,7 +6,7 @@
* @license Apache-2.0
*/
import Utils from "../Utils";
import Utils from "../Utils.mjs";
/**

View file

@ -5,8 +5,8 @@
* @copyright Crown Copyright 2019
* @license Apache-2.0
*/
import OperationError from "../errors/OperationError";
import Utils from "../Utils";
import OperationError from "../errors/OperationError.mjs";
import Utils from "../Utils.mjs";
/**
* Provided default Enigma rotor set.

View file

@ -6,7 +6,7 @@
* @license Apache-2.0
*
*/
import Stream from "./Stream";
import Stream from "./Stream.mjs";
/**
* A categorised table of file types, including signatures to identify them and functions

View file

@ -6,8 +6,8 @@
* @license Apache-2.0
*
*/
import {FILE_SIGNATURES} from "./FileSignatures";
import {sendStatusMessage} from "../Utils";
import {FILE_SIGNATURES} from "./FileSignatures.mjs";
import {sendStatusMessage} from "../Utils.mjs";
/**

View file

@ -7,8 +7,8 @@
* @license Apache-2.0
*/
import Utils from "../Utils";
import CryptoApi from "crypto-api/src/crypto-api";
import Utils from "../Utils.mjs";
import CryptoApi from "crypto-api/src/crypto-api.mjs";
/**

View file

@ -6,7 +6,7 @@
* @license Apache-2.0
*/
import Utils from "../Utils";
import Utils from "../Utils.mjs";
/**

View file

@ -8,8 +8,8 @@
* @license Apache-2.0
*/
import Utils from "../Utils";
import OperationError from "../errors/OperationError";
import Utils from "../Utils.mjs";
import OperationError from "../errors/OperationError.mjs";
/**
* Parses an IPv4 CIDR range (e.g. 192.168.0.0/24) and displays information about it.

View file

@ -6,7 +6,7 @@
* @license Apache-2.0
*/
import OperationError from "../errors/OperationError";
import OperationError from "../errors/OperationError.mjs";
/**
* Gaussian blurs an image.

View file

@ -1,8 +1,8 @@
import OperationConfig from "../config/OperationConfig.json";
import Utils, { isWorkerEnvironment } from "../Utils";
import Recipe from "../Recipe";
import Dish from "../Dish";
import {detectFileType} from "./FileType";
import Utils, { isWorkerEnvironment } from "../Utils.mjs";
import Recipe from "../Recipe.mjs";
import Dish from "../Dish.mjs";
import {detectFileType} from "./FileType.mjs";
import chiSquared from "chi-squared";
/**

View file

@ -10,8 +10,8 @@
*
*/
import OperationError from "../errors/OperationError";
import { isWorkerEnvironment } from "../Utils";
import OperationError from "../errors/OperationError.mjs";
import { isWorkerEnvironment } from "../Utils.mjs";
import kbpgp from "kbpgp";
import * as es6promisify from "es6-promisify";
const promisify = es6promisify.default ? es6promisify.default.promisify : es6promisify.promisify;

View file

@ -1,4 +1,4 @@
import Utils from "../Utils";
import Utils from "../Utils.mjs";
/**
* Protobuf lib. Contains functions to decode protobuf serialised

View file

@ -6,7 +6,7 @@
* @license Apache-2.0
*/
import { toHex, fromHex } from "./Hex";
import { toHex, fromHex } from "./Hex.mjs";
/**
* Formats Distinguished Name (DN) strings.

View file

@ -6,11 +6,11 @@
* @license Apache-2.0
*/
import OperationError from "../errors/OperationError";
import OperationError from "../errors/OperationError.mjs";
import jsQR from "jsqr";
import qr from "qr-image";
import jimp from "jimp";
import Utils from "../Utils";
import Utils from "../Utils.mjs";
/**
* Parses a QR code image from an image

View file

@ -6,9 +6,9 @@
* @copyright Crown Copyright 2019
* @license Apache-2.0
*/
import OperationError from "../errors/OperationError";
import * as Enigma from "../lib/Enigma";
import Utils from "../Utils";
import OperationError from "../errors/OperationError.mjs";
import * as Enigma from "../lib/Enigma.mjs";
import Utils from "../Utils.mjs";
/**
* A set of example Typex rotors. No Typex rotor wirings are publicly available, so these are

View file

@ -6,7 +6,7 @@
* @license Apache-2.0
*/
import zlibAndGzip from "zlibjs/bin/zlib_and_gzip.min";
import zlibAndGzip from "zlibjs/bin/zlib_and_gzip.min.js";
const Zlib = zlibAndGzip.Zlib;