@speleotica/frcsdata 4.0.2 → 4.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. package/FrcsPlotFile.d.ts +1 -1
  2. package/FrcsPlotShot.d.ts +1 -1
  3. package/FrcsShot.d.ts +1 -1
  4. package/FrcsShot.js +2 -3
  5. package/FrcsSurveyFile.d.ts +1 -1
  6. package/FrcsTrip.d.ts +2 -2
  7. package/FrcsTripSummary.d.ts +1 -1
  8. package/FrcsTripSummaryFile.d.ts +1 -1
  9. package/formatFrcsShot.js +7 -6
  10. package/index.js +11 -11
  11. package/node/index.js +6 -9
  12. package/package.json +26 -124
  13. package/parseFrcsPlotFile.js +4 -3
  14. package/parseFrcsSurveyFile.js +126 -107
  15. package/parseFrcsTripSummaryFile.js +5 -4
  16. package/string/index.js +8 -11
  17. package/es/FrcsPlotFile.js +0 -6
  18. package/es/FrcsPlotShot.js +0 -6
  19. package/es/FrcsShot.js +0 -14
  20. package/es/FrcsSurveyFile.js +0 -6
  21. package/es/FrcsTrip.js +0 -6
  22. package/es/FrcsTripSummary.js +0 -6
  23. package/es/FrcsTripSummaryFile.js +0 -6
  24. package/es/formatFrcsShot.js +0 -75
  25. package/es/formatFrcsShot.spec.js +0 -141
  26. package/es/index.js +0 -96
  27. package/es/node/index.js +0 -20
  28. package/es/node/parseFrcsPlotFile.spec.js +0 -167
  29. package/es/node/parseFrcsSurveyFile.spec.js +0 -314
  30. package/es/node/parseFrcsTripSummaryFile.spec.js +0 -78
  31. package/es/parseFrcsPlotFile.js +0 -135
  32. package/es/parseFrcsSurveyFile.js +0 -485
  33. package/es/parseFrcsTripSummaryFile.js +0 -73
  34. package/es/string/index.js +0 -21
  35. package/es/string/parseFrcsPlotFile.spec.js +0 -179
  36. package/es/string/parseFrcsSurveyFile.spec.js +0 -644
  37. package/formatFrcsShot.spec.js +0 -139
  38. package/node/parseFrcsPlotFile.spec.js +0 -181
  39. package/node/parseFrcsSurveyFile.spec.js +0 -328
  40. package/node/parseFrcsTripSummaryFile.spec.js +0 -104
  41. package/string/parseFrcsPlotFile.spec.js +0 -182
  42. package/string/parseFrcsSurveyFile.spec.js +0 -673
  43. package/yarn.lock +0 -9542
package/FrcsPlotFile.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import { UnitizedNumber, Length } from '@speleotica/unitized';
2
2
  import { FrcsPlotShot } from './FrcsPlotShot';
3
3
  import { SegmentParseError } from 'parse-segment';
4
- export declare type FrcsPlotFile = {
4
+ export type FrcsPlotFile = {
5
5
  totalLength: UnitizedNumber<Length>;
6
6
  shots: Array<FrcsPlotShot>;
7
7
  errors?: Array<SegmentParseError> | null;
package/FrcsPlotShot.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { UnitizedNumber, Length } from '@speleotica/unitized';
2
- export declare type FrcsPlotShot = {
2
+ export type FrcsPlotShot = {
3
3
  toName: string;
4
4
  isSurface?: boolean | null;
5
5
  fromNumber: number;
package/FrcsShot.d.ts CHANGED
@@ -4,7 +4,7 @@ export declare enum FrcsShotKind {
4
4
  Horizontal = "H",
5
5
  Diagonal = "D"
6
6
  }
7
- export declare type FrcsShot = {
7
+ export type FrcsShot = {
8
8
  /**
9
9
  * Name of from station
10
10
  */
package/FrcsShot.js CHANGED
@@ -4,10 +4,9 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.FrcsShotKind = void 0;
7
- var FrcsShotKind = /*#__PURE__*/function (FrcsShotKind) {
7
+ var FrcsShotKind = exports.FrcsShotKind = /*#__PURE__*/function (FrcsShotKind) {
8
8
  FrcsShotKind["Normal"] = " ";
9
9
  FrcsShotKind["Horizontal"] = "H";
10
10
  FrcsShotKind["Diagonal"] = "D";
11
11
  return FrcsShotKind;
12
- }({});
13
- exports.FrcsShotKind = FrcsShotKind;
12
+ }({});
@@ -1,6 +1,6 @@
1
1
  import { FrcsTrip } from './FrcsTrip';
2
2
  import { SegmentParseError } from 'parse-segment';
3
- export declare type FrcsSurveyFile = {
3
+ export type FrcsSurveyFile = {
4
4
  cave?: string | null;
5
5
  location?: string | null;
6
6
  comment?: string | null;
package/FrcsTrip.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { Unit, Length, Angle } from '@speleotica/unitized';
2
2
  import { FrcsShot } from './FrcsShot';
3
- export declare type FrcsTripHeader = {
3
+ export type FrcsTripHeader = {
4
4
  name: string;
5
5
  comment?: string | null;
6
6
  section?: string | null;
@@ -14,7 +14,7 @@ export declare type FrcsTripHeader = {
14
14
  hasBacksightAzimuth?: boolean | null;
15
15
  hasBacksightInclination?: boolean | null;
16
16
  };
17
- export declare type FrcsTrip = {
17
+ export type FrcsTrip = {
18
18
  header: FrcsTripHeader;
19
19
  shots: Array<FrcsShot>;
20
20
  };
@@ -1,5 +1,5 @@
1
1
  import { UnitizedNumber, Length } from '@speleotica/unitized';
2
- export declare type FrcsTripSummary = {
2
+ export type FrcsTripSummary = {
3
3
  tripNumber: number;
4
4
  tripIndex: number;
5
5
  date: Date;
@@ -1,6 +1,6 @@
1
1
  import { FrcsTripSummary } from './FrcsTripSummary';
2
2
  import { SegmentParseError } from 'parse-segment';
3
- export declare type FrcsTripSummaryFile = {
3
+ export type FrcsTripSummaryFile = {
4
4
  errors?: Array<SegmentParseError> | null;
5
5
  tripSummaries: Array<FrcsTripSummary | undefined>;
6
6
  };
package/formatFrcsShot.js CHANGED
@@ -4,7 +4,7 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports["default"] = formatFrcsShot;
7
- var _FrcsShot = require("./FrcsShot");
7
+ var _FrcsShot = require("./FrcsShot.js");
8
8
  var _unitized = require("@speleotica/unitized");
9
9
  var STATION_WIDTH = 5;
10
10
  var EMPTY_STATION = ' '.repeat(STATION_WIDTH);
@@ -53,20 +53,21 @@ function formatInches(distance) {
53
53
  return formatNumber(INCHES_WIDTH)(Math.round(distance.get(_unitized.Length.inches) % 12));
54
54
  }
55
55
  function formatFrcsShot(shot, header) {
56
- var _shot$frontsightAzimu, _shot$backsightAzimut, _shot$frontsightIncli, _shot$verticalDistanc, _shot$backsightInclin, _shot$toLruds, _shot$toLruds$left, _shot$toLruds2, _shot$toLruds2$right, _shot$toLruds3, _shot$toLruds3$up, _shot$toLruds4, _shot$toLruds4$down;
56
+ var _shot$frontsightAzimu, _shot$backsightAzimut, _shot$frontsightIncli, _shot$verticalDistanc, _shot$backsightInclin, _shot$toLruds, _shot$toLruds2, _shot$toLruds3, _shot$toLruds4;
57
57
  var azimuthUnit = header.azimuthUnit,
58
58
  inclinationUnit = header.inclinationUnit;
59
59
  var distanceUnit = header.distanceUnit;
60
60
  var inches = distanceUnit === _unitized.Length.inches;
61
61
  if (inches) distanceUnit = _unitized.Length.feet;
62
62
  if (!shot.to) {
63
- var _shot$fromLruds, _shot$fromLruds$left, _shot$fromLruds2, _shot$fromLruds2$righ, _shot$fromLruds3, _shot$fromLruds3$up, _shot$fromLruds4, _shot$fromLruds4$down;
63
+ var _shot$fromLruds, _shot$fromLruds2, _shot$fromLruds3, _shot$fromLruds4;
64
64
  return [formatStation(shot.from), EMPTY_STATION, EMPTY_DISTANCE, ' ',
65
65
  // kind
66
66
  ' ',
67
67
  // exclude
68
- EMPTY_AZIMUTH, EMPTY_AZIMUTH, EMPTY_INCLINATION, EMPTY_INCLINATION, formatLrud((_shot$fromLruds = shot.fromLruds) === null || _shot$fromLruds === void 0 ? void 0 : (_shot$fromLruds$left = _shot$fromLruds.left) === null || _shot$fromLruds$left === void 0 ? void 0 : _shot$fromLruds$left.get(distanceUnit)), formatLrud((_shot$fromLruds2 = shot.fromLruds) === null || _shot$fromLruds2 === void 0 ? void 0 : (_shot$fromLruds2$righ = _shot$fromLruds2.right) === null || _shot$fromLruds2$righ === void 0 ? void 0 : _shot$fromLruds2$righ.get(distanceUnit)), formatLrud((_shot$fromLruds3 = shot.fromLruds) === null || _shot$fromLruds3 === void 0 ? void 0 : (_shot$fromLruds3$up = _shot$fromLruds3.up) === null || _shot$fromLruds3$up === void 0 ? void 0 : _shot$fromLruds3$up.get(distanceUnit)), formatLrud((_shot$fromLruds4 = shot.fromLruds) === null || _shot$fromLruds4 === void 0 ? void 0 : (_shot$fromLruds4$down = _shot$fromLruds4.down) === null || _shot$fromLruds4$down === void 0 ? void 0 : _shot$fromLruds4$down.get(distanceUnit))].join('');
68
+ EMPTY_AZIMUTH, EMPTY_AZIMUTH, EMPTY_INCLINATION, EMPTY_INCLINATION, formatLrud((_shot$fromLruds = shot.fromLruds) === null || _shot$fromLruds === void 0 || (_shot$fromLruds = _shot$fromLruds.left) === null || _shot$fromLruds === void 0 ? void 0 : _shot$fromLruds.get(distanceUnit)), formatLrud((_shot$fromLruds2 = shot.fromLruds) === null || _shot$fromLruds2 === void 0 || (_shot$fromLruds2 = _shot$fromLruds2.right) === null || _shot$fromLruds2 === void 0 ? void 0 : _shot$fromLruds2.get(distanceUnit)), formatLrud((_shot$fromLruds3 = shot.fromLruds) === null || _shot$fromLruds3 === void 0 || (_shot$fromLruds3 = _shot$fromLruds3.up) === null || _shot$fromLruds3 === void 0 ? void 0 : _shot$fromLruds3.get(distanceUnit)), formatLrud((_shot$fromLruds4 = shot.fromLruds) === null || _shot$fromLruds4 === void 0 || (_shot$fromLruds4 = _shot$fromLruds4.down) === null || _shot$fromLruds4 === void 0 ? void 0 : _shot$fromLruds4.get(distanceUnit))].join('');
69
69
  }
70
70
  var distColumnValue = shot.kind === _FrcsShot.FrcsShotKind.Horizontal ? shot.horizontalDistance : shot.distance;
71
- return [formatStation(shot.to), formatStation(shot.from), inches ? formatFeet(distColumnValue) : formatDistance(distColumnValue === null || distColumnValue === void 0 ? void 0 : distColumnValue.get(distanceUnit)), inches ? formatInches(distColumnValue) : shot.kind, inches ? shot.kind : shot.excludeDistance ? '*' : ' ', formatAzimuth((_shot$frontsightAzimu = shot.frontsightAzimuth) === null || _shot$frontsightAzimu === void 0 ? void 0 : _shot$frontsightAzimu.get(azimuthUnit)), formatAzimuth((_shot$backsightAzimut = shot.backsightAzimuth) === null || _shot$backsightAzimut === void 0 ? void 0 : _shot$backsightAzimut.get(azimuthUnit)), shot.kind === _FrcsShot.FrcsShotKind.Normal ? formatInclination((_shot$frontsightIncli = shot.frontsightInclination) === null || _shot$frontsightIncli === void 0 ? void 0 : _shot$frontsightIncli.get(inclinationUnit)) : formatVerticalDistance((_shot$verticalDistanc = shot.verticalDistance) === null || _shot$verticalDistanc === void 0 ? void 0 : _shot$verticalDistanc.get(distanceUnit)), shot.kind === _FrcsShot.FrcsShotKind.Normal ? formatInclination((_shot$backsightInclin = shot.backsightInclination) === null || _shot$backsightInclin === void 0 ? void 0 : _shot$backsightInclin.get(inclinationUnit)) : EMPTY_INCLINATION, formatLrud((_shot$toLruds = shot.toLruds) === null || _shot$toLruds === void 0 ? void 0 : (_shot$toLruds$left = _shot$toLruds.left) === null || _shot$toLruds$left === void 0 ? void 0 : _shot$toLruds$left.get(distanceUnit)), formatLrud((_shot$toLruds2 = shot.toLruds) === null || _shot$toLruds2 === void 0 ? void 0 : (_shot$toLruds2$right = _shot$toLruds2.right) === null || _shot$toLruds2$right === void 0 ? void 0 : _shot$toLruds2$right.get(distanceUnit)), formatLrud((_shot$toLruds3 = shot.toLruds) === null || _shot$toLruds3 === void 0 ? void 0 : (_shot$toLruds3$up = _shot$toLruds3.up) === null || _shot$toLruds3$up === void 0 ? void 0 : _shot$toLruds3$up.get(distanceUnit)), formatLrud((_shot$toLruds4 = shot.toLruds) === null || _shot$toLruds4 === void 0 ? void 0 : (_shot$toLruds4$down = _shot$toLruds4.down) === null || _shot$toLruds4$down === void 0 ? void 0 : _shot$toLruds4$down.get(distanceUnit))].join('');
72
- }
71
+ return [formatStation(shot.to), formatStation(shot.from), inches ? formatFeet(distColumnValue) : formatDistance(distColumnValue === null || distColumnValue === void 0 ? void 0 : distColumnValue.get(distanceUnit)), inches ? formatInches(distColumnValue) : shot.kind, inches ? shot.kind : shot.excludeDistance ? '*' : ' ', formatAzimuth((_shot$frontsightAzimu = shot.frontsightAzimuth) === null || _shot$frontsightAzimu === void 0 ? void 0 : _shot$frontsightAzimu.get(azimuthUnit)), formatAzimuth((_shot$backsightAzimut = shot.backsightAzimuth) === null || _shot$backsightAzimut === void 0 ? void 0 : _shot$backsightAzimut.get(azimuthUnit)), shot.kind === _FrcsShot.FrcsShotKind.Normal ? formatInclination((_shot$frontsightIncli = shot.frontsightInclination) === null || _shot$frontsightIncli === void 0 ? void 0 : _shot$frontsightIncli.get(inclinationUnit)) : formatVerticalDistance((_shot$verticalDistanc = shot.verticalDistance) === null || _shot$verticalDistanc === void 0 ? void 0 : _shot$verticalDistanc.get(distanceUnit)), shot.kind === _FrcsShot.FrcsShotKind.Normal ? formatInclination((_shot$backsightInclin = shot.backsightInclination) === null || _shot$backsightInclin === void 0 ? void 0 : _shot$backsightInclin.get(inclinationUnit)) : EMPTY_INCLINATION, formatLrud((_shot$toLruds = shot.toLruds) === null || _shot$toLruds === void 0 || (_shot$toLruds = _shot$toLruds.left) === null || _shot$toLruds === void 0 ? void 0 : _shot$toLruds.get(distanceUnit)), formatLrud((_shot$toLruds2 = shot.toLruds) === null || _shot$toLruds2 === void 0 || (_shot$toLruds2 = _shot$toLruds2.right) === null || _shot$toLruds2 === void 0 ? void 0 : _shot$toLruds2.get(distanceUnit)), formatLrud((_shot$toLruds3 = shot.toLruds) === null || _shot$toLruds3 === void 0 || (_shot$toLruds3 = _shot$toLruds3.up) === null || _shot$toLruds3 === void 0 ? void 0 : _shot$toLruds3.get(distanceUnit)), formatLrud((_shot$toLruds4 = shot.toLruds) === null || _shot$toLruds4 === void 0 || (_shot$toLruds4 = _shot$toLruds4.down) === null || _shot$toLruds4 === void 0 ? void 0 : _shot$toLruds4.get(distanceUnit))].join('');
72
+ }
73
+ module.exports = exports.default;
package/index.js CHANGED
@@ -82,14 +82,14 @@ Object.defineProperty(exports, "parseFrcsTripSummaryFile", {
82
82
  return _parseFrcsTripSummaryFile["default"];
83
83
  }
84
84
  });
85
- var _FrcsTrip = require("./FrcsTrip");
86
- var _FrcsShot = require("./FrcsShot");
87
- var _FrcsSurveyFile = require("./FrcsSurveyFile");
88
- var _parseFrcsSurveyFile = _interopRequireDefault(require("./parseFrcsSurveyFile"));
89
- var _FrcsPlotShot = require("./FrcsPlotShot");
90
- var _FrcsPlotFile = require("./FrcsPlotFile");
91
- var _parseFrcsPlotFile = _interopRequireDefault(require("./parseFrcsPlotFile"));
92
- var _FrcsTripSummary = require("./FrcsTripSummary");
93
- var _FrcsTripSummaryFile = require("./FrcsTripSummaryFile");
94
- var _parseFrcsTripSummaryFile = _interopRequireDefault(require("./parseFrcsTripSummaryFile"));
95
- var _formatFrcsShot = _interopRequireDefault(require("./formatFrcsShot"));
85
+ var _FrcsTrip = require("./FrcsTrip.js");
86
+ var _FrcsShot = require("./FrcsShot.js");
87
+ var _FrcsSurveyFile = require("./FrcsSurveyFile.js");
88
+ var _parseFrcsSurveyFile = _interopRequireDefault(require("./parseFrcsSurveyFile.js"));
89
+ var _FrcsPlotShot = require("./FrcsPlotShot.js");
90
+ var _FrcsPlotFile = require("./FrcsPlotFile.js");
91
+ var _parseFrcsPlotFile = _interopRequireDefault(require("./parseFrcsPlotFile.js"));
92
+ var _FrcsTripSummary = require("./FrcsTripSummary.js");
93
+ var _FrcsTripSummaryFile = require("./FrcsTripSummaryFile.js");
94
+ var _parseFrcsTripSummaryFile = _interopRequireDefault(require("./parseFrcsTripSummaryFile.js"));
95
+ var _formatFrcsShot = _interopRequireDefault(require("./formatFrcsShot.js"));
package/node/index.js CHANGED
@@ -7,17 +7,14 @@ Object.defineProperty(exports, "__esModule", {
7
7
  exports.parseFrcsTripSummaryFile = exports.parseFrcsSurveyFile = exports.parseFrcsPlotFile = void 0;
8
8
  var _fs = _interopRequireDefault(require("fs"));
9
9
  var _readline = _interopRequireDefault(require("readline"));
10
- var _parseFrcsSurveyFile2 = _interopRequireDefault(require("../parseFrcsSurveyFile"));
11
- var _parseFrcsPlotFile2 = _interopRequireDefault(require("../parseFrcsPlotFile"));
12
- var _parseFrcsTripSummaryFile2 = _interopRequireDefault(require("../parseFrcsTripSummaryFile"));
10
+ var _parseFrcsSurveyFile2 = _interopRequireDefault(require("../parseFrcsSurveyFile.js"));
11
+ var _parseFrcsPlotFile2 = _interopRequireDefault(require("../parseFrcsPlotFile.js"));
12
+ var _parseFrcsTripSummaryFile2 = _interopRequireDefault(require("../parseFrcsTripSummaryFile.js"));
13
13
  var convert = function convert(fn) {
14
14
  return function (file) {
15
15
  return fn(file, _readline["default"].createInterface(_fs["default"].createReadStream(file)));
16
16
  };
17
17
  };
18
- var parseFrcsSurveyFile = convert(_parseFrcsSurveyFile2["default"]);
19
- exports.parseFrcsSurveyFile = parseFrcsSurveyFile;
20
- var parseFrcsPlotFile = convert(_parseFrcsPlotFile2["default"]);
21
- exports.parseFrcsPlotFile = parseFrcsPlotFile;
22
- var parseFrcsTripSummaryFile = convert(_parseFrcsTripSummaryFile2["default"]);
23
- exports.parseFrcsTripSummaryFile = parseFrcsTripSummaryFile;
18
+ var parseFrcsSurveyFile = exports.parseFrcsSurveyFile = convert(_parseFrcsSurveyFile2["default"]);
19
+ var parseFrcsPlotFile = exports.parseFrcsPlotFile = convert(_parseFrcsPlotFile2["default"]);
20
+ var parseFrcsTripSummaryFile = exports.parseFrcsTripSummaryFile = convert(_parseFrcsTripSummaryFile2["default"]);
package/package.json CHANGED
@@ -1,75 +1,11 @@
1
1
  {
2
2
  "name": "@speleotica/frcsdata",
3
- "version": "4.0.2",
3
+ "version": "4.0.4",
4
4
  "description": "parser for Chip Hopper's survey data format used in Fisher Ridge Cave System",
5
- "main": "index.js",
6
5
  "sideEffects": false,
7
- "scripts": {
8
- "lint": "eslint $npm_package_config_lint",
9
- "lint:fix": "eslint $npm_package_config_lint",
10
- "lint:watch": "esw --watch $npm_package_config_lint",
11
- "prettier": "prettier --write .babelrc.js *.json *.md *.ts '{src,test}/**/*.{js,ts}'",
12
- "prettier:check": "prettier --list-different .babelrc.js *.json *.md *.ts '{src,test}/**/*.{js,ts}'",
13
- "tsc": "tsc --noEmit",
14
- "tsc:watch": "npm run tsc -- --watch",
15
- "clean": "rimraf es lib $(cd src; ls) *.js *.d.ts",
16
- "build": "npm run clean && npm run build:types && npm run build:js",
17
- "build:types": "tsc --emitDeclarationOnly",
18
- "build:js": "babel src --out-dir es --extensions \".ts\" --source-maps inline && cross-env BABEL_ENV=es5 babel src --out-dir . --extensions \".ts\"",
19
- "test": "cross-env NODE_ENV=test BABEL_ENV=es5 mocha $npm_package_config_mocha && cross-env NODE_ENV=test BABEL_ENV=coverage nyc --reporter=lcov --reporter=text mocha $npm_package_config_mocha",
20
- "test:watch": "cross-env NODE_ENV=test BABEL_ENV=test mocha $npm_package_config_mocha --watch --watch-extensions js,ts",
21
- "test:debug": "cross-env NODE_ENV=test BABEL_ENV=test mocha --inspect-brk $npm_package_config_mocha",
22
- "codecov": "nyc report --reporter=text-lcov > coverage.lcov; codecov",
23
- "prepublishOnly": "npm run clean && npm run prettier:check && npm run lint && npm test && npm run build",
24
- "open:coverage": "open coverage/lcov-report/index.html",
25
- "semantic-release": "semantic-release"
26
- },
27
- "config": {
28
- "lint": "--cache --ext .js,.ts src test",
29
- "mocha": "test/configure.js 'src/**/*.spec.ts'",
30
- "commitizen": {
31
- "path": "cz-conventional-changelog"
32
- }
33
- },
34
6
  "publishConfig": {
35
7
  "access": "public"
36
8
  },
37
- "husky": {
38
- "hooks": {
39
- "pre-commit": "lint-staged && npm run lint && npm run tsc",
40
- "commit-msg": "commitlint -e $GIT_PARAMS",
41
- "pre-push": "npm test"
42
- }
43
- },
44
- "lint-staged": {
45
- "*.{js,ts,json,css,md}": [
46
- "prettier --write",
47
- "git add"
48
- ]
49
- },
50
- "commitlint": {
51
- "extends": [
52
- "@jedwards1211/commitlint-config"
53
- ]
54
- },
55
- "prettier": {
56
- "semi": false,
57
- "singleQuote": true,
58
- "trailingComma": "es5"
59
- },
60
- "nyc": {
61
- "include": [
62
- "src/**/*.ts"
63
- ],
64
- "exclude": [
65
- "src/**/*.spec.ts"
66
- ],
67
- "require": [
68
- "@babel/register"
69
- ],
70
- "sourceMap": false,
71
- "instrument": false
72
- },
73
9
  "repository": {
74
10
  "type": "git",
75
11
  "url": "https://github.com/speleotica/frcsdata.git"
@@ -83,68 +19,34 @@
83
19
  "url": "https://github.com/speleotica/frcsdata/issues"
84
20
  },
85
21
  "homepage": "https://github.com/speleotica/frcsdata#readme",
86
- "devDependencies": {
87
- "@babel/cli": "^7.22.5",
88
- "@babel/core": "^7.22.5",
89
- "@babel/plugin-proposal-class-properties": "^7.18.6",
90
- "@babel/plugin-proposal-export-default-from": "^7.22.5",
91
- "@babel/plugin-proposal-export-namespace-from": "^7.18.9",
92
- "@babel/plugin-proposal-nullish-coalescing-operator": "^7.18.6",
93
- "@babel/plugin-proposal-object-rest-spread": "^7.20.7",
94
- "@babel/plugin-proposal-optional-chaining": "^7.21.0",
95
- "@babel/plugin-syntax-dynamic-import": "^7.0.0",
96
- "@babel/plugin-transform-runtime": "^7.22.5",
97
- "@babel/preset-env": "^7.22.5",
98
- "@babel/preset-typescript": "^7.22.5",
99
- "@babel/register": "^7.22.5",
100
- "@commitlint/cli": "^6.0.2",
101
- "@commitlint/config-conventional": "^6.0.2",
102
- "@jedwards1211/commitlint-config": "^1.0.0",
103
- "@jedwards1211/eslint-config-typescript": "^1.0.0",
104
- "@types/chai": "^4.2.0",
105
- "@types/mocha": "^5.2.7",
106
- "@types/node": "^12.12.12",
107
- "babel-eslint": "^10.1.0",
108
- "babel-plugin-istanbul": "^6.1.1",
109
- "chai": "^4.2.0",
110
- "codecov": "^3.1.0",
111
- "copy": "^0.3.2",
112
- "cross-env": "^5.2.0",
113
- "eslint": "^5.9.0",
114
- "eslint-config-prettier": "^3.3.0",
115
- "eslint-watch": "^4.0.2",
116
- "husky": "^1.1.4",
117
- "istanbul": "^0.4.5",
118
- "lint-staged": "^8.0.4",
119
- "mocha": "^6.2.1",
120
- "nyc": "^13.1.0",
121
- "prettier": "^1.15.2",
122
- "prettier-eslint": "^8.8.2",
123
- "rimraf": "^2.6.0",
124
- "semantic-release": "^15.13.31",
125
- "typescript": "^3.7.2"
126
- },
127
22
  "dependencies": {
128
- "@babel/runtime": "^7.1.5",
23
+ "@babel/runtime": "^7.18.6",
129
24
  "@speleotica/unitized": "^2.0.0",
130
25
  "parse-segment": "^1.5.1"
131
26
  },
132
- "renovate": {
133
- "extends": [
134
- ":separateMajorReleases",
135
- ":combinePatchMinorReleases",
136
- ":ignoreUnstable",
137
- ":prImmediately",
138
- ":renovatePrefix",
139
- ":updateNotScheduled",
140
- ":preserveSemverRanges",
141
- ":semanticPrefixFixDepsChoreOthers",
142
- ":automergeDisabled",
143
- "group:monorepos"
144
- ],
145
- "automerge": true,
146
- "major": {
147
- "automerge": false
27
+ "main": "index.js",
28
+ "types": "index.d.ts",
29
+ "exports": {
30
+ "./package.json": "./package.json",
31
+ ".": {
32
+ "types": "./index.d.ts",
33
+ "default": "./index.js"
34
+ },
35
+ "./node": {
36
+ "types": "./node/index.d.ts",
37
+ "default": "./node/index.js"
38
+ },
39
+ "./string": {
40
+ "types": "./string/index.d.ts",
41
+ "default": "./string/index.js"
42
+ },
43
+ "./*": {
44
+ "types": "./*.d.ts",
45
+ "default": "./*.js"
148
46
  }
149
- }
47
+ },
48
+ "engines": {
49
+ "node": ">=16"
50
+ },
51
+ "packageManager": "pnpm@8.11.0"
150
52
  }
@@ -9,8 +9,8 @@ var _regenerator = _interopRequireDefault(require("@babel/runtime/regenerator"))
9
9
  var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
10
10
  var _unitized = require("@speleotica/unitized");
11
11
  var _parseSegment = require("parse-segment");
12
- function _asyncIterator(iterable) { var method, async, sync, retry = 2; for ("undefined" != typeof Symbol && (async = Symbol.asyncIterator, sync = Symbol.iterator); retry--;) { if (async && null != (method = iterable[async])) return method.call(iterable); if (sync && null != (method = iterable[sync])) return new AsyncFromSyncIterator(method.call(iterable)); async = "@@asyncIterator", sync = "@@iterator"; } throw new TypeError("Object is not async iterable"); }
13
- function AsyncFromSyncIterator(s) { function AsyncFromSyncIteratorContinuation(r) { if (Object(r) !== r) return Promise.reject(new TypeError(r + " is not an object.")); var done = r.done; return Promise.resolve(r.value).then(function (value) { return { value: value, done: done }; }); } return AsyncFromSyncIterator = function AsyncFromSyncIterator(s) { this.s = s, this.n = s.next; }, AsyncFromSyncIterator.prototype = { s: null, n: null, next: function next() { return AsyncFromSyncIteratorContinuation(this.n.apply(this.s, arguments)); }, "return": function _return(value) { var ret = this.s["return"]; return void 0 === ret ? Promise.resolve({ value: value, done: !0 }) : AsyncFromSyncIteratorContinuation(ret.apply(this.s, arguments)); }, "throw": function _throw(value) { var thr = this.s["return"]; return void 0 === thr ? Promise.reject(value) : AsyncFromSyncIteratorContinuation(thr.apply(this.s, arguments)); } }, new AsyncFromSyncIterator(s); }
12
+ function _asyncIterator(r) { var n, t, o, e = 2; for ("undefined" != typeof Symbol && (t = Symbol.asyncIterator, o = Symbol.iterator); e--;) { if (t && null != (n = r[t])) return n.call(r); if (o && null != (n = r[o])) return new AsyncFromSyncIterator(n.call(r)); t = "@@asyncIterator", o = "@@iterator"; } throw new TypeError("Object is not async iterable"); }
13
+ function AsyncFromSyncIterator(r) { function AsyncFromSyncIteratorContinuation(r) { if (Object(r) !== r) return Promise.reject(new TypeError(r + " is not an object.")); var n = r.done; return Promise.resolve(r.value).then(function (r) { return { value: r, done: n }; }); } return AsyncFromSyncIterator = function AsyncFromSyncIterator(r) { this.s = r, this.n = r.next; }, AsyncFromSyncIterator.prototype = { s: null, n: null, next: function next() { return AsyncFromSyncIteratorContinuation(this.n.apply(this.s, arguments)); }, "return": function _return(r) { var n = this.s["return"]; return void 0 === n ? Promise.resolve({ value: r, done: !0 }) : AsyncFromSyncIteratorContinuation(n.apply(this.s, arguments)); }, "throw": function _throw(r) { var n = this.s["return"]; return void 0 === n ? Promise.reject(r) : AsyncFromSyncIteratorContinuation(n.apply(this.s, arguments)); } }, new AsyncFromSyncIterator(r); }
14
14
  /**
15
15
  * Parses data from a calculated survey file. These look like so:
16
16
  <pre> 123.182259
@@ -264,4 +264,5 @@ function _parseFrcsPlotFile() {
264
264
  }, _callee, null, [[10, 70, 74, 84], [75,, 79, 83]]);
265
265
  }));
266
266
  return _parseFrcsPlotFile.apply(this, arguments);
267
- }
267
+ }
268
+ module.exports = exports.default;