@metrichor/epi2me-web
Advanced tools
Comparing version 4.0.4186216 to 4.0.4201189
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.buildNestedUserDefined = void 0; | ||
exports.validateAndAddAttribute = exports.buildNestedUserDefined = void 0; | ||
/* | ||
@@ -20,1 +20,13 @@ Helper methods that are likely to be used by any applicaton using API. | ||
exports.buildNestedUserDefined = buildNestedUserDefined; | ||
function validateAndAddAttribute(attributeValue, instanceAttributes, attributeDef) { | ||
// eslint-disable-next-line @typescript-eslint/camelcase | ||
const { format, idAttribute: id_attribute } = attributeDef; | ||
const valueRE = new RegExp(format, 'g'); | ||
attributeValue && | ||
valueRE.test(attributeValue) && | ||
instanceAttributes.push({ | ||
id_attribute, | ||
value: attributeValue, | ||
}); | ||
} | ||
exports.validateAndAddAttribute = validateAndAddAttribute; |
@@ -16,1 +16,12 @@ /* | ||
} | ||
export function validateAndAddAttribute(attributeValue, instanceAttributes, attributeDef) { | ||
// eslint-disable-next-line @typescript-eslint/camelcase | ||
const { format, idAttribute: id_attribute } = attributeDef; | ||
const valueRE = new RegExp(format, 'g'); | ||
attributeValue && | ||
valueRE.test(attributeValue) && | ||
instanceAttributes.push({ | ||
id_attribute, | ||
value: attributeValue, | ||
}); | ||
} |
@@ -12,3 +12,3 @@ { | ||
"private": false, | ||
"version": "4.0.4186216", | ||
"version": "4.0.4201189", | ||
"main": "cjs/index-web.js", | ||
@@ -15,0 +15,0 @@ "module": "esm/index-web.js", |
import { ObjectDict } from './ObjectDict'; | ||
import { Index } from './runtime-typecast'; | ||
export declare function buildNestedUserDefined(flatUserDefined: ObjectDict): ObjectDict<ObjectDict>; | ||
export declare function validateAndAddAttribute(attributeValue: string, instanceAttributes: { | ||
id_attribute: Index; | ||
value: string; | ||
}[], attributeDef: { | ||
idAttribute: Index; | ||
format: string; | ||
}): void; |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
2608784
29097