Socket
Socket
Sign inDemoInstall

@ltht-react/utils

Package Overview
Dependencies
Maintainers
6
Versions
319
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ltht-react/utils - npm Package Compare versions

Comparing version 1.0.1 to 1.1.0

110

CHANGELOG.md

@@ -10,6 +10,2 @@ # Change Log

## [0.1.19](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.18...@ltht-react/utils@0.1.19) (2020-10-29)

@@ -19,6 +15,2 @@

## [0.1.18](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.17...@ltht-react/utils@0.1.18) (2020-09-10)

@@ -28,7 +20,2 @@

## [0.1.17](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.16...@ltht-react/utils@0.1.17) (2020-09-01)

@@ -38,6 +25,2 @@

## [0.1.16](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.15...@ltht-react/utils@0.1.16) (2020-08-21)

@@ -47,6 +30,2 @@

## [0.1.15](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.14...@ltht-react/utils@0.1.15) (2020-08-19)

@@ -56,6 +35,2 @@

## [0.1.14](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.13...@ltht-react/utils@0.1.14) (2020-08-19)

@@ -65,6 +40,2 @@

## [0.1.13](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.12...@ltht-react/utils@0.1.13) (2020-08-18)

@@ -74,6 +45,2 @@

## [0.1.12](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.11...@ltht-react/utils@0.1.12) (2020-08-11)

@@ -83,6 +50,2 @@

## [0.1.11](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.10...@ltht-react/utils@0.1.11) (2020-08-10)

@@ -92,6 +55,2 @@

## [0.1.10](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.9...@ltht-react/utils@0.1.10) (2020-08-05)

@@ -101,6 +60,2 @@

## [0.1.9](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.8...@ltht-react/utils@0.1.9) (2020-08-05)

@@ -110,6 +65,2 @@

## [0.1.8](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.7...@ltht-react/utils@0.1.8) (2020-08-05)

@@ -119,6 +70,2 @@

## [0.1.6](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.5...@ltht-react/utils@0.1.6) (2020-08-04)

@@ -128,7 +75,2 @@

## [0.1.5](https://ssh.github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.4...@ltht-react/utils@0.1.5) (2020-04-03)

@@ -138,6 +80,2 @@

## [0.1.4](https://ssh.github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.3...@ltht-react/utils@0.1.4) (2020-03-12)

@@ -147,6 +85,2 @@

## [0.1.3](https://ssh.github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.2...@ltht-react/utils@0.1.3) (2020-03-06)

@@ -156,6 +90,2 @@

## [0.1.2](https://ssh.github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.1...@ltht-react/utils@0.1.2) (2020-02-27)

@@ -165,6 +95,2 @@

## [0.1.1](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.1.0...@ltht-react/utils@0.1.1) (2020-02-26)

@@ -174,6 +100,2 @@

## [0.0.10](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.0.9...@ltht-react/utils@0.0.10) (2020-01-30)

@@ -183,6 +105,2 @@

## [0.0.9](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.0.8...@ltht-react/utils@0.0.9) (2020-01-21)

@@ -192,6 +110,2 @@

## [0.0.8](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.0.7...@ltht-react/utils@0.0.8) (2020-01-21)

@@ -201,6 +115,2 @@

## [0.0.7](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.0.6...@ltht-react/utils@0.0.7) (2020-01-17)

@@ -210,6 +120,2 @@

## [0.0.6](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.0.5...@ltht-react/utils@0.0.6) (2020-01-17)

@@ -219,6 +125,2 @@

## [0.0.4](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.0.3...@ltht-react/utils@0.0.4) (2020-01-07)

@@ -228,6 +130,2 @@

## [0.0.3](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.0.2...@ltht-react/utils@0.0.3) (2020-01-07)

@@ -237,6 +135,2 @@

## [0.0.2](https://github.com/ltht-epr/ltht-react/compare/@ltht-react/utils@0.0.1...@ltht-react/utils@0.0.2) (2020-01-07)

@@ -246,8 +140,4 @@

## 0.0.1 (2020-01-07)
**Note:** Version bump only for package @ltht-react/utils

6

lib/atoms/allergy-intolerance-category-code.js

@@ -6,9 +6,5 @@ "use strict";

if (categories === void 0) { categories = []; }
return categories
.map(function (category) {
return category && title_case_1.titleCase(category);
})
.join(', ');
return categories.map(function (category) { return category && title_case_1.titleCase(category); }).join(', ');
};
exports.default = allergyIntoleranceCategoryCodeDisplaySummary;
//# sourceMappingURL=allergy-intolerance-category-code.js.map

@@ -8,7 +8,3 @@ "use strict";

var codings = (codeableConcept === null || codeableConcept === void 0 ? void 0 : codeableConcept.coding) || [];
var display = codings
.map(function (coding) {
return coding === null || coding === void 0 ? void 0 : coding.display;
})
.join(', ');
var display = codings.map(function (coding) { return coding === null || coding === void 0 ? void 0 : coding.display; }).join(', ');
if ((display === null || display === void 0 ? void 0 : display.length) === 0) {

@@ -23,7 +19,3 @@ display = (_a = codeableConcept === null || codeableConcept === void 0 ? void 0 : codeableConcept.text) !== null && _a !== void 0 ? _a : '';

var codings = codeableConcept.coding || [];
var code = codings
.map(function (coding) {
return coding === null || coding === void 0 ? void 0 : coding.code;
})
.join(', ');
var code = codings.map(function (coding) { return coding === null || coding === void 0 ? void 0 : coding.code; }).join(', ');
return code;

@@ -34,8 +26,3 @@ };

if (codeableConcept === void 0) { codeableConcept = []; }
var textSummary = codeableConcept
.map(function (item) {
var _a;
return (_a = item === null || item === void 0 ? void 0 : item.text) !== null && _a !== void 0 ? _a : codeableConceptDisplaySummary(item);
})
.join(', ');
var textSummary = codeableConcept.map(function (item) { var _a; return (_a = item === null || item === void 0 ? void 0 : item.text) !== null && _a !== void 0 ? _a : codeableConceptDisplaySummary(item); }).join(', ');
return textSummary;

@@ -42,0 +29,0 @@ };

16

lib/atoms/index.js

@@ -10,18 +10,22 @@ "use strict";

var __exportStar = (this && this.__exportStar) || function(m, exports) {
for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p);
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
};
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.titleCase = exports.resourceReferenceDisplaySummary = exports.periodSummaryText = exports.metadataSourceSummaryText = exports.allergyIntoleranceCategoryCodeDisplaySummary = void 0;
var allergy_intolerance_category_code_1 = require("./allergy-intolerance-category-code");
Object.defineProperty(exports, "allergyIntoleranceCategoryCodeDisplaySummary", { enumerable: true, get: function () { return allergy_intolerance_category_code_1.default; } });
Object.defineProperty(exports, "allergyIntoleranceCategoryCodeDisplaySummary", { enumerable: true, get: function () { return __importDefault(allergy_intolerance_category_code_1).default; } });
__exportStar(require("./codeable-concept"), exports);
var metadata_1 = require("./metadata");
Object.defineProperty(exports, "metadataSourceSummaryText", { enumerable: true, get: function () { return metadata_1.default; } });
Object.defineProperty(exports, "metadataSourceSummaryText", { enumerable: true, get: function () { return __importDefault(metadata_1).default; } });
__exportStar(require("./partial-date-time"), exports);
var period_1 = require("./period");
Object.defineProperty(exports, "periodSummaryText", { enumerable: true, get: function () { return period_1.default; } });
Object.defineProperty(exports, "periodSummaryText", { enumerable: true, get: function () { return __importDefault(period_1).default; } });
var resource_reference_1 = require("./resource-reference");
Object.defineProperty(exports, "resourceReferenceDisplaySummary", { enumerable: true, get: function () { return resource_reference_1.default; } });
Object.defineProperty(exports, "resourceReferenceDisplaySummary", { enumerable: true, get: function () { return __importDefault(resource_reference_1).default; } });
var title_case_1 = require("./title-case");
Object.defineProperty(exports, "titleCase", { enumerable: true, get: function () { return title_case_1.default; } });
Object.defineProperty(exports, "titleCase", { enumerable: true, get: function () { return __importDefault(title_case_1).default; } });
__exportStar(require("./patient"), exports);
//# sourceMappingURL=index.js.map

@@ -7,7 +7,3 @@ "use strict";

}
var result = metadata.dataSources
.map(function (dataSource) {
return dataSource === null || dataSource === void 0 ? void 0 : dataSource.display;
})
.join(', ');
var result = metadata.dataSources.map(function (dataSource) { return dataSource === null || dataSource === void 0 ? void 0 : dataSource.display; }).join(', ');
return result;

@@ -14,0 +10,0 @@ };

@@ -11,15 +11,11 @@ "use strict";

var minuteFormat = '2-digit';
exports.formatDate = function (date) {
return date
.toLocaleString(locale, { day: dayFormat, month: monthFormat, year: yearFormat })
.split(' ')
.join('-');
var formatDate = function (date) {
return date.toLocaleString(locale, { day: dayFormat, month: monthFormat, year: yearFormat }).split(' ').join('-');
};
exports.formatTime = function (date) {
return date
.toLocaleString(locale, { hour: hourFormat, minute: minuteFormat, hour12: false })
.split(' ')
.join(':');
exports.formatDate = formatDate;
var formatTime = function (date) {
return date.toLocaleString(locale, { hour: hourFormat, minute: minuteFormat, hour12: false }).split(' ').join(':');
};
exports.partialDateTimeText = function (partialDateTime) {
exports.formatTime = formatTime;
var partialDateTimeText = function (partialDateTime) {
if (!partialDateTime || !partialDateTime.value) {

@@ -48,2 +44,3 @@ return '';

};
exports.partialDateTimeText = partialDateTimeText;
//# sourceMappingURL=partial-date-time.js.map

@@ -28,8 +28,3 @@ "use strict";

var dateValue = '2013-02-03T13:15:16+00:00';
var partialDateTime = function (kind) {
return {
value: dateValue,
kind: kind,
};
};
var partialDateTime = function (kind) { return ({ value: dateValue, kind: kind }); };
//# sourceMappingURL=partial-date-time.test.js.map

@@ -6,5 +6,3 @@ "use strict";

var title_case_1 = require("./title-case");
var daysInMonth = function (iMonth, iYear) {
return 32 - new Date(iYear, iMonth, 32).getDate();
};
var daysInMonth = function (iMonth, iYear) { return 32 - new Date(iYear, iMonth, 32).getDate(); };
var formatPatientAddress = function (patient) {

@@ -11,0 +9,0 @@ var _a;

@@ -5,7 +5,3 @@ "use strict";

if (resourceReferences === void 0) { resourceReferences = []; }
var displaySummary = resourceReferences
.map(function (resourceReference) {
return resourceReference === null || resourceReference === void 0 ? void 0 : resourceReference.display;
})
.join(', ');
var displaySummary = resourceReferences.map(function (resourceReference) { return resourceReference === null || resourceReference === void 0 ? void 0 : resourceReference.display; }).join(', ');
return displaySummary;

@@ -12,0 +8,0 @@ };

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.titleCase = void 0;
exports.titleCase = function (value) {
var titleCase = function (value) {
if (!value || value.length === 0) {

@@ -11,8 +11,7 @@ return '';

.split(/\s|_/)
.map(function (word) {
return word.replace(word[0], word[0].toUpperCase());
})
.map(function (word) { return word.replace(word[0], word[0].toUpperCase()); })
.join(' ');
};
exports.titleCase = titleCase;
exports.default = exports.titleCase;
//# sourceMappingURL=title-case.js.map

@@ -10,3 +10,3 @@ "use strict";

var __exportStar = (this && this.__exportStar) || function(m, exports) {
for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p);
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
};

@@ -13,0 +13,0 @@ Object.defineProperty(exports, "__esModule", { value: true });

{
"name": "@ltht-react/utils",
"version": "1.0.1",
"version": "1.1.0",
"description": "> TODO: description",

@@ -25,5 +25,5 @@ "author": "Jonny Smith <jonny.asmith@gmail.com>",

"dependencies": {
"@ltht-react/types": "^0.0.28"
"@ltht-react/types": "^0.1.0"
},
"gitHead": "f8bfbac4d78be3c724441713cb4318fbb3ded297"
"gitHead": "4f7dfa52f4994f98c1bc6059c3b732d713e2d2c0"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc