node-zugferd
Version:
A Node.js library for creating ZUGFeRD/Factur-X compliant documents. Generating XML and embedding it into PDF/A files, enabling seamless e-invoicing and digital document compliance.
108 lines (104 loc) • 3.18 kB
JavaScript
;
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
for (var name in all)
__defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
if (from && typeof from === "object" || typeof from === "function") {
for (let key of __getOwnPropNames(from))
if (!__hasOwnProp.call(to, key) && key !== except)
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
}
return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
// src/codelists/untdid-5305.gen.ts
var untdid_5305_gen_exports = {};
__export(untdid_5305_gen_exports, {
UNTDID_5305: () => UNTDID_5305,
Untdid5305: () => Untdid5305,
untdid5305Code: () => untdid5305Code
});
module.exports = __toCommonJS(untdid_5305_gen_exports);
// src/codelists/index.ts
var getByPath = (obj, path) => path.split(".").reduce((acc, key) => acc?.[key], obj);
var createEnum = (data, options) => {
return Object.fromEntries(
data.map((item) => [
getByPath(item, options.keyProp),
getByPath(item, options.valueProp)
])
);
};
// src/codelists/untdid-5305.gen.ts
var UNTDID_5305 = [
{
key: "STANDARD_RATE",
name: "Standard rate",
value: "S",
semantic_model: "Standard rate"
},
{
key: "ZERO_RATED_GOODS",
name: "Zero rated goods",
value: "Z",
semantic_model: "Zero rated goods"
},
{
key: "EXEMPT_FROM_TAX",
name: "Exempt from tax",
value: "E",
semantic_model: "Exempt from tax"
},
{
key: "VAT_REVERSE_CHARGE",
name: "VAT Reverse charge",
value: "AE",
semantic_model: "VAT reverse charge"
},
{
key: "VAT_EXEMPT_FOR_EEA_INTRA_COMMUNITY_SUPPLY_OF_GOODS_AND_SERVICES",
name: "VAT exempt for EEA intra-community supply of goods and services",
value: "K",
semantic_model: "VAT exempt for intra community supply of goods"
},
{
key: "FREE_EXPORT_ITEM_TAX_NOT_CHARGED",
name: "Free export item, tax not charged",
value: "G",
semantic_model: "Free export item, tax not charged"
},
{
key: "SERVICE_OUTSIDE_SCOPE_OF_TAX",
name: "Service outside scope of tax",
value: "O",
semantic_model: "Services outside scope of tax"
},
{
key: "CANARY_ISLANDS_GENERAL_INDIRECT_TAX",
name: "Canary Islands general indirect tax",
value: "L",
semantic_model: "Canary Islands General Indirect Tax"
},
{
key: "TAX_FOR_PRODUCTION_SERVICES_AND_IMPORTATION_IN_CEUTA_AND_MELILLA",
name: "Tax for production, services and importation in Ceuta and Melilla",
value: "M",
semantic_model: "Liable for IPSI"
}
];
var untdid5305Code = UNTDID_5305.map(({ value }) => value);
var Untdid5305 = createEnum(UNTDID_5305, {
keyProp: "key",
valueProp: "value"
});
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
UNTDID_5305,
Untdid5305,
untdid5305Code
});