@bookipi/htmlgenerator 1.8.4-alpha1 → 1.8.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.
- package/dist/index.js +130 -74
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +130 -74
- package/dist/index.modern.js.map +1 -1
- package/dist/subscriptionInvoiceHtml.module.css +253 -0
- package/package.json +1 -1
- package/.vscode/common.settings.json +0 -38
package/dist/index.modern.js
CHANGED
|
@@ -13421,61 +13421,59 @@ var contractHtml = (function (props) {
|
|
|
13421
13421
|
return html;
|
|
13422
13422
|
});
|
|
13423
13423
|
|
|
13424
|
-
var
|
|
13425
|
-
|
|
13426
|
-
|
|
13427
|
-
|
|
13428
|
-
|
|
13429
|
-
|
|
13430
|
-
|
|
13431
|
-
|
|
13432
|
-
|
|
13433
|
-
|
|
13434
|
-
|
|
13435
|
-
|
|
13436
|
-
|
|
13437
|
-
|
|
13438
|
-
|
|
13439
|
-
|
|
13440
|
-
|
|
13441
|
-
|
|
13442
|
-
|
|
13443
|
-
|
|
13444
|
-
var
|
|
13445
|
-
|
|
13446
|
-
|
|
13447
|
-
|
|
13448
|
-
|
|
13449
|
-
|
|
13450
|
-
|
|
13451
|
-
var
|
|
13452
|
-
|
|
13453
|
-
|
|
13454
|
-
|
|
13455
|
-
|
|
13456
|
-
|
|
13457
|
-
|
|
13458
|
-
|
|
13459
|
-
|
|
13460
|
-
|
|
13461
|
-
|
|
13462
|
-
|
|
13463
|
-
|
|
13464
|
-
|
|
13465
|
-
|
|
13466
|
-
|
|
13467
|
-
|
|
13468
|
-
|
|
13469
|
-
|
|
13470
|
-
discount: t ? t('Discount') : 'Discount'
|
|
13471
|
-
};
|
|
13424
|
+
var styleSheet = "\n<style>\n @import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;900&family=Lato:wght@400;700&display=swap');\n\n .bookipay-invoice {\n width: 100%;\n max-width: 600px;\n background-color: white;\n display: flex;\n border-radius: 16px;\n flex-direction: column;\n overflow: hidden;\n font-family: 'Inter', sans-serif;\n line-height: 1.2;\n color: black;\n font-size: 16px;\n }\n\n .invoice-content {\n padding: 40px 30px;\n }\n\n .invoice-header {\n display: flex;\n padding: 10px;\n margin-bottom: 40px;\n justify-content: space-between;\n }\n\n .invoice-footer {\n padding: 30px 38px 40px;\n background-color: rgb(245, 246, 250);\n font-size: 12px;\n }\n\n .invoice-footer p {\n display: block;\n margin: 0;\n }\n\n .invoice-footer-logo {\n height: 20px;\n margin-bottom: 12px;\n }\n\n .invoice-logo {\n object-fit: contain;\n max-height: 52px;\n width: auto;\n height: auto;\n }\n\n .invoice-body {\n color: rgb(15, 23, 42);\n font-size: 16px;\n }\n\n .invoice-company {\n text-align: right;\n }\n\n .invoice-spacing {\n margin-bottom: 4px;\n }\n\n .invoice-semi-bold {\n color: rgb(15, 23, 42);\n font-weight: 600;\n font-size: 16px;\n }\n\n .invoice-bold {\n font-family: 'Lato', sans-serif;\n color: black;\n font-weight: 700;\n font-size: 20px;\n }\n\n .invoice-subtitle {\n color: rgba(0, 0, 0, 0.6);\n font-size: 14px;\n }\n\n .invoice-subtitle2 {\n color: rgb(147, 154, 172);\n font-size: 14px;\n }\n\n .invoice-subtitle3 {\n color: rgb(100, 116, 139);\n font-size: 14px;\n }\n\n .invoice-subtitle4 {\n font-size: 10px;\n }\n\n .invoice-summary {\n background-color: rgb(245, 246, 250);\n padding: 32px 24px;\n border-radius: 16px;\n margin-bottom: 40px;\n }\n\n .invoice-summary-total {\n display: flex;\n margin-top: 24px;\n flex-direction: column;\n }\n\n .invoice-summary-customer {\n display: flex;\n flex-direction: row;\n align-items: flex-start;\n justify-content: space-between;\n gap: 16px;\n }\n\n .invoice-summary-customer-column {\n flex: 1;\n overflow-wrap:anywhere;\n }\n\n .invoice-customer-email {\n text-align: right;\n }\n\n .invoice-order-header {\n padding: 8px 0;\n margin-bottom: 8px;\n border-bottom: 1px solid rgba(0, 0, 0, 0.06);\n display: flex;\n justify-content: space-between;\n }\n\n .invoice-order-container {\n display: flex;\n justify-content: space-between;\n }\n\n .invoice-order-item {\n padding: 12px 0px 5px;\n }\n\n .invoice-order-details {\n display: flex;\n justify-content: space-between;\n }\n\n .invoice-item-details {\n color: rgb(100, 116, 139);\n font-size: 14px;\n margin-top: 4px;\n }\n\n .invoice-tax {\n display: flex;\n justify-content: space-between;\n margin-top: 8px;\n }\n\n .invoice-payment {\n display: flex;\n padding: 12px 0px 16px;\n justify-content: space-between;\n border-top: 1px solid rgba(0, 0, 0, 0.06);\n margin-top: 15px;\n }\n\n .invoice-card {\n display: flex;\n padding: 8px 0px;\n }\n\n .invoice-card img {\n height: 24px;\n margin-right: 6px;\n }\n\n .invoice-bill-to {\n display: none;\n }\n\n .invoice-order-item-amount {\n font-size: 16px;\n white-space: nowrap;\n }\n\n .invoice-card-number {\n color: rgb(15, 23, 42);\n font-size: 16px;\n font-weight: 400;\n }\n\n .invoice-total-amount {\n font-size: 18px;\n text-align: right;\n }\n\n @media (max-width: 600px) {\n .bookipay-invoice {\n border-radius: 0;\n }\n }\n\n @media (max-width: 799px) {\n .invoice-header {\n flex-direction: column;\n padding: 10px 0;\n }\n\n .invoice-company {\n text-align: left;\n }\n\n .invoice-logo {\n max-width: 100px;\n margin-bottom: 16px;\n }\n\n .invoice-header,\n .invoice-summary {\n margin-bottom: 20px;\n }\n\n .invoice-summary {\n margin-left: -30px;\n margin-right: -30px;\n border-radius: 0;\n padding: 32px 30px;\n }\n\n .invoice-content {\n padding: 20px 30px;\n }\n\n .invoice-bill-to {\n display: flex;\n }\n }\n\n @media (max-width: 399px) {\n .footer-actions {\n flex-direction: column;\n }\n\n .footer-action {\n margin-bottom: 12px;\n }\n\n footer {\n margin: 30px 0;\n }\n\n footer p {\n margin-top: 0;\n }\n }\n\n @media print {\n * {\n color-adjust: exact;\n -webkit-print-color-adjust: exact;\n print-color-adjust: exact;\n }\n\n .invoice-footer {\n width: 100%;\n max-width: 100%;\n margin: 0;\n }\n\n .bookipay-invoice {\n max-width: 100%;\n }\n\n @page {\n margin: 0;\n }\n\n body {\n margin: 1.6cm;\n }\n }\n</style>\n";
|
|
13425
|
+
|
|
13426
|
+
function formatPrice(price, currency) {
|
|
13427
|
+
if (price === void 0) {
|
|
13428
|
+
price = 0;
|
|
13429
|
+
}
|
|
13430
|
+
if (currency === void 0) {
|
|
13431
|
+
currency = 'USD';
|
|
13432
|
+
}
|
|
13433
|
+
return (price ? Number(price / 100).toFixed(2) : '0') + " " + currency;
|
|
13434
|
+
}
|
|
13435
|
+
function renderAddressItems(addressItems) {
|
|
13436
|
+
if (addressItems === void 0) {
|
|
13437
|
+
addressItems = [];
|
|
13438
|
+
}
|
|
13439
|
+
return addressItems.filter(function (item) {
|
|
13440
|
+
return !!item;
|
|
13441
|
+
}).join(', ');
|
|
13442
|
+
}
|
|
13443
|
+
function Header(_ref) {
|
|
13444
|
+
var logoUrl = _ref.logoUrl,
|
|
13445
|
+
companyName = _ref.companyName,
|
|
13446
|
+
invoiceNo = _ref.invoiceNo,
|
|
13447
|
+
invoiceDate = _ref.invoiceDate;
|
|
13448
|
+
return "\n <div class=\"invoice-header\">\n <img class=\"invoice-logo\" src=" + logoUrl + " />\n <div class=\"invoice-company\">\n <div class=\"invoice-company-name invoice-semi-bold invoice-spacing\">\n " + companyName + "\n </div>\n <div class=\"invoice-number invoice-subtitle invoice-spacing\">\n " + invoiceNo + "\n </div>\n <div class=\"invoice-date invoice-subtitle invoice-spacing\">\n " + invoiceDate + "\n </div>\n </div>\n </div>\n ";
|
|
13449
|
+
}
|
|
13450
|
+
function InvoiceSummaryCard(params) {
|
|
13451
|
+
var email = params.email,
|
|
13452
|
+
companyName = params.companyName,
|
|
13453
|
+
businessNumber = params.businessNumber,
|
|
13454
|
+
address = params.address,
|
|
13455
|
+
total = params.total,
|
|
13456
|
+
currency = params.currency,
|
|
13457
|
+
defaultLang = params.defaultLang;
|
|
13458
|
+
var hasAddressLine = (address === null || address === void 0 ? void 0 : address.address1) || (address === null || address === void 0 ? void 0 : address.address2) || (address === null || address === void 0 ? void 0 : address.address3);
|
|
13459
|
+
var hasAddress = (address === null || address === void 0 ? void 0 : address.city) || (address === null || address === void 0 ? void 0 : address.zip) || (address === null || address === void 0 ? void 0 : address.country);
|
|
13460
|
+
return "\n <div class=\"invoice-summary\">\n <div class=\"invoice-summary-customer\">\n <div class=\"invoice-summary-customer-column\">\n <div class=\"invoice-bold invoice-spacing\">" + companyName + "</div>\n " + (businessNumber ? "<div class=\"invoice-subtitle2\">" + businessNumber + "</div>" : '') + "\n " + (hasAddressLine ? "<div class=\"invoice-subtitle2\">\n " + renderAddressItems([address.address1, address.address2, address.address3]) + "\n </div>" : '') + "\n " + (hasAddress ? "<div class=\"invoice-subtitle2\">\n " + renderAddressItems([address.city, address.zip, address.country]) + "\n </div>" : '') + "\n </div>\n <div class=\"invoice-customer-email invoice-subtitle2 invoice-summary-customer-column\">\n " + email + "\n </div>\n </div>\n <div class=\"invoice-summary-total\">\n <div class=\"invoice-subtitle3 invoice-spacing\">\n " + defaultLang.total + "\n </div>\n <div class=\"invoice-summary-total-value invoice-bold invoice-spacing\">\n " + formatPrice(total, currency) + "\n </div>\n </div>\n </div>\n ";
|
|
13461
|
+
}
|
|
13462
|
+
function OrderSummary(params) {
|
|
13463
|
+
var amountPaid = params.amountPaid,
|
|
13464
|
+
invoiceItems = params.invoiceItems,
|
|
13465
|
+
cardBrand = params.cardBrand,
|
|
13466
|
+
cardNumber = params.cardNumber,
|
|
13467
|
+
cardLogo = params.cardLogo,
|
|
13468
|
+
currency = params.currency,
|
|
13469
|
+
defaultLang = params.defaultLang;
|
|
13472
13470
|
var hasDiscount = invoiceItems.some(function (item) {
|
|
13473
13471
|
return item.type === 'discount' && item.total > 0;
|
|
13474
13472
|
});
|
|
13475
13473
|
var hasTax = invoiceItems.some(function (item) {
|
|
13476
13474
|
return item.type === 'tax' && item.total > 0;
|
|
13477
13475
|
});
|
|
13478
|
-
|
|
13476
|
+
function renderItem(item) {
|
|
13479
13477
|
var title = item.name || item.description;
|
|
13480
13478
|
var showSubtotal = hasTax && hasDiscount;
|
|
13481
13479
|
if (!showSubtotal && item.type === 'subtotal') {
|
|
@@ -13486,30 +13484,88 @@ var subscriptionInvoiceHtml = (function (_ref) {
|
|
|
13486
13484
|
var color = isDiscount ? '#C81E1E' : 'inherit';
|
|
13487
13485
|
var label = isDiscount ? defaultLang.discount + " (" + title + ")" : title;
|
|
13488
13486
|
if (isDiscount && total === 0) return '';
|
|
13489
|
-
|
|
13490
|
-
|
|
13491
|
-
|
|
13487
|
+
var hasDescription = item.description && item.description !== item.name && item.description.trim() !== '';
|
|
13488
|
+
return "\n <div class=\"invoice-order-item\">\n <div class=\"invoice-order-details\">\n <div>\n <div class=\"invoice-spacing invoice-body3\" style=\"color:" + color + ";\">\n " + label + "\n </div>\n " + (hasDescription ? "<div class=\"invoice-item-details\">" + item.description + "</div>" : '') + "\n </div>\n <div class=\"invoice-order-item-amount\" style=\"color:" + color + ";\">\n " + formatPrice(total, currency) + "\n </div>\n </div>\n </div>\n ";
|
|
13489
|
+
}
|
|
13490
|
+
function renderItems() {
|
|
13492
13491
|
var rendered = '';
|
|
13493
|
-
|
|
13492
|
+
invoiceItems.forEach(function (item) {
|
|
13494
13493
|
rendered += renderItem(item);
|
|
13495
13494
|
});
|
|
13496
13495
|
return rendered;
|
|
13496
|
+
}
|
|
13497
|
+
return "\n <div class=\"invoice-order\">\n <div class=\"invoice-order-header\">\n <div class=\"invoice-subtitle3\">" + defaultLang.item + "</div>\n <div class=\"invoice-subtitle3\">" + defaultLang.amount + "</div>\n </div>\n <div class=\"invoice-order-item-container\">\n " + renderItems() + "\n <div class=\"invoice-payment\">\n <div class=\"invoice-bold\" style=\"font-size:'16px;\">\n " + defaultLang.totalCharged + "\n </div>\n <div class=\"invoice-body3\">\n <div class=\"invoice-bold invoice-spacing invoice-total-amount\">\n " + formatPrice(amountPaid, currency) + "\n </div>\n </div>\n </div>\n " + (cardBrand && cardNumber ? "\n <div class=\"invoice-card\">\n <img src=" + cardLogo + " alt=" + cardBrand + " />\n <div class=\"invoice-card-number\">\n " + (cardBrand.charAt(0).toUpperCase() + cardBrand.slice(1)) + " \u2022\u2022\u2022\u2022 " + cardNumber + "\n </div>\n </div>\n " : '') + "\n </div>\n </div>\n ";
|
|
13498
|
+
}
|
|
13499
|
+
function Footer(_ref2) {
|
|
13500
|
+
var logoUrl = _ref2.logoUrl;
|
|
13501
|
+
return "\n <div class=\"invoice-footer invoice-subtitle2\">\n <img class=\"invoice-footer-logo\" src=" + logoUrl + " />\n <p>\xA92025 Bookipi Pty Ltd.</p>\n <p>9 George St, North Strathfield NSW 2137, Australia</p>\n <p>ABN: 91617668185</p>\n </div>";
|
|
13502
|
+
}
|
|
13503
|
+
function SubscriptionInvoiceHtml(_ref3) {
|
|
13504
|
+
var vendor = _ref3.vendor,
|
|
13505
|
+
invoice = _ref3.invoice,
|
|
13506
|
+
customer = _ref3.customer,
|
|
13507
|
+
includeHtmlWrapper = _ref3.includeHtmlWrapper,
|
|
13508
|
+
t = _ref3.t;
|
|
13509
|
+
var _ref4 = vendor != null ? vendor : {},
|
|
13510
|
+
vendorName = _ref4.name,
|
|
13511
|
+
vendorLogoUrl = _ref4.logoUrl,
|
|
13512
|
+
businessNumber = _ref4.businessNumber,
|
|
13513
|
+
address = _ref4.address;
|
|
13514
|
+
var _ref5 = invoice != null ? invoice : {},
|
|
13515
|
+
invoiceNumber = _ref5.no,
|
|
13516
|
+
total = _ref5.total,
|
|
13517
|
+
amountPaid = _ref5.amountPaid,
|
|
13518
|
+
currency = _ref5.currency,
|
|
13519
|
+
transaction = _ref5.transaction,
|
|
13520
|
+
date = _ref5.date,
|
|
13521
|
+
invoiceItems = _ref5.items;
|
|
13522
|
+
var _ref6 = transaction != null ? transaction : {},
|
|
13523
|
+
cardNumber = _ref6.cardNumber,
|
|
13524
|
+
cardBrand = _ref6.cardBrand,
|
|
13525
|
+
cardLogo = _ref6.cardLogo;
|
|
13526
|
+
var _ref7 = customer != null ? customer : {},
|
|
13527
|
+
companyName = _ref7.name,
|
|
13528
|
+
email = _ref7.email;
|
|
13529
|
+
var logoUrl = vendorLogoUrl != null ? vendorLogoUrl : 'https://web.bookipi.com/images/logos/logo-bookipi.png';
|
|
13530
|
+
var defaultLang = {
|
|
13531
|
+
invoiceNo: t ? t('Invoice #', {
|
|
13532
|
+
no: invoiceNumber
|
|
13533
|
+
}) : "Invoice #" + invoiceNumber,
|
|
13534
|
+
total: t ? t('Total') : 'Total',
|
|
13535
|
+
billTo: t ? t('Bill to') : 'Bill to',
|
|
13536
|
+
item: t ? t('Item') : 'Item',
|
|
13537
|
+
amount: t ? t('Amount') : 'Amount',
|
|
13538
|
+
totalCharged: t ? t('Total charged') : 'Total charged',
|
|
13539
|
+
discount: t ? t('Discount') : 'Discount'
|
|
13497
13540
|
};
|
|
13498
|
-
var
|
|
13499
|
-
|
|
13500
|
-
|
|
13501
|
-
|
|
13502
|
-
|
|
13503
|
-
|
|
13504
|
-
|
|
13505
|
-
|
|
13506
|
-
|
|
13507
|
-
|
|
13508
|
-
|
|
13541
|
+
var html = "\n " + (includeHtmlWrapper ? '<!DOCTYPE html>\n<html>\n<head>\n<meta charset="utf-8">\n<title>Invoice</title>' : '') + "\n " + styleSheet + "\n " + (includeHtmlWrapper ? '</head>' : '') + "\n <div class=\"bookipay-invoice\">\n <div class=\"invoice-content\">\n " + Header({
|
|
13542
|
+
logoUrl: logoUrl,
|
|
13543
|
+
companyName: vendorName,
|
|
13544
|
+
invoiceNo: defaultLang.invoiceNo,
|
|
13545
|
+
invoiceDate: date
|
|
13546
|
+
}) + "\n " + InvoiceSummaryCard({
|
|
13547
|
+
email: email,
|
|
13548
|
+
companyName: companyName,
|
|
13549
|
+
businessNumber: businessNumber,
|
|
13550
|
+
address: address,
|
|
13551
|
+
total: total,
|
|
13552
|
+
currency: currency,
|
|
13553
|
+
defaultLang: defaultLang
|
|
13554
|
+
}) + "\n " + OrderSummary({
|
|
13555
|
+
amountPaid: amountPaid,
|
|
13556
|
+
invoiceItems: invoiceItems,
|
|
13557
|
+
cardBrand: cardBrand,
|
|
13558
|
+
cardNumber: cardNumber,
|
|
13559
|
+
cardLogo: cardLogo,
|
|
13560
|
+
currency: currency,
|
|
13561
|
+
defaultLang: defaultLang
|
|
13562
|
+
}) + "\n </div>\n " + Footer({
|
|
13563
|
+
logoUrl: logoUrl
|
|
13564
|
+
}) + "\n </div>\n " + (includeHtmlWrapper ? '</body></html>' : '') + "\n ";
|
|
13509
13565
|
return {
|
|
13510
13566
|
html: html
|
|
13511
13567
|
};
|
|
13512
|
-
}
|
|
13568
|
+
}
|
|
13513
13569
|
|
|
13514
13570
|
var _document$invoice$est;
|
|
13515
13571
|
var langJP = (_document$invoice$est = {
|
|
@@ -14298,7 +14354,7 @@ var processHtml = function processHtml(_ref) {
|
|
|
14298
14354
|
return html$P(_templateObject5$2 || (_templateObject5$2 = _taggedTemplateLiteralLoose(["\n <div class=\"slide slide--process\">\n <div class=\"content\">\n <h2 class=\"title\">", "</h2>\n <ul\n class=\"bullets-ul\"\n style=\"display:flex;gap:24px;list-style:none;padding:16px 0 0;justify-content:center;width:auto;border-top:1px solid ", ";\"\n >\n ", "\n </ul>\n </div>\n </div>\n "])), escapeHtml(slide.title), escapeHtml(borderColor), listItems);
|
|
14299
14355
|
};
|
|
14300
14356
|
|
|
14301
|
-
var _templateObject$T, _templateObject2$u, _templateObject3$f, _templateObject4$5
|
|
14357
|
+
var _templateObject$T, _templateObject2$u, _templateObject3$f, _templateObject4$5;
|
|
14302
14358
|
var html$Q = String.raw;
|
|
14303
14359
|
var teamMemberHtml = function teamMemberHtml(_ref) {
|
|
14304
14360
|
var _ref$slide = _ref.slide,
|
|
@@ -14308,18 +14364,18 @@ var teamMemberHtml = function teamMemberHtml(_ref) {
|
|
|
14308
14364
|
return html$Q(_templateObject$T || (_templateObject$T = _taggedTemplateLiteralLoose(["\n <div class=\"slide\">\n <div class=\"content\">\n <h2 class=\"title\">", "</h2>\n </div>\n </div>\n "])), escapeHtml(slide.title || ''));
|
|
14309
14365
|
}
|
|
14310
14366
|
var isRow = members.length > 1;
|
|
14311
|
-
var imageStyle = isRow ? '
|
|
14367
|
+
var imageStyle = isRow ? 'height:auto;' : 'max-height:30%;';
|
|
14312
14368
|
var memberHtml = members.map(function (member) {
|
|
14313
14369
|
var name = (member === null || member === void 0 ? void 0 : member.name) || '';
|
|
14314
14370
|
var role = (member === null || member === void 0 ? void 0 : member.role) || '';
|
|
14315
14371
|
var bio = (member === null || member === void 0 ? void 0 : member.bio) || '';
|
|
14316
14372
|
var img = getImage(member === null || member === void 0 ? void 0 : member.imageSource) || '';
|
|
14317
|
-
return html$Q(_templateObject2$u || (_templateObject2$u = _taggedTemplateLiteralLoose(["\n <div\n style=\"flex:1;min-width:0;display:flex;flex-direction:column;align-items:flex-start;box-sizing:border-box;\"\n >\n <span class=\"subtitle\" style=\"margin:0;font-weight:600;\"\n >", "</span\n >\n <span class=\"text\" style=\"margin:0;\">", "</span>\n <div
|
|
14373
|
+
return html$Q(_templateObject2$u || (_templateObject2$u = _taggedTemplateLiteralLoose(["\n <div\n style=\"flex:1;min-width:0;display:flex;flex-direction:column;align-items:flex-start;box-sizing:border-box;\"\n >\n <span class=\"subtitle\" style=\"margin:0;font-weight:600;\"\n >", "</span\n >\n <span class=\"text\" style=\"margin:0;color:var(--theme-text-color);\"\n >", "</span\n >\n <div\n style=\"display:flex;flex-direction:column;align-items:flex-start;width:100%;\"\n >\n <img\n src=\"", "\"\n alt=\"", "-avatar\"\n style=\"border-radius:8px;flex-shrink:0;max-width:100%;", "object-fit:contain;\"\n />\n ", "\n </div>\n </div>\n "])), escapeHtml(name), escapeHtml(role), escapeHtml(img), escapeHtml(name), imageStyle, bio ? html$Q(_templateObject3$f || (_templateObject3$f = _taggedTemplateLiteralLoose(["<p class=\"text\" style=\"margin:0;text-align:left;\">\n ", "\n </p>"])), escapeHtml(bio)) : '');
|
|
14318
14374
|
}).join('');
|
|
14319
|
-
return html$Q(_templateObject4$5 || (_templateObject4$5 = _taggedTemplateLiteralLoose(["\n <div class=\"slide\">\n <div class=\"content\" style=\"align-items:flex-start;\">\n ", "\n <div style=\"display:flex;gap:24px;width:100
|
|
14375
|
+
return html$Q(_templateObject4$5 || (_templateObject4$5 = _taggedTemplateLiteralLoose(["\n <div class=\"slide\">\n <div class=\"content\" style=\"align-items:flex-start;\">\n <h2 class=\"title\" style=\"text-align:left;\">\n ", "\n </h2>\n <div style=\"display:flex;gap:24px;margin-top:16px;width:100%;\">\n ", "\n </div>\n </div>\n </div>\n "])), escapeHtml(slide.title || ''), memberHtml);
|
|
14320
14376
|
};
|
|
14321
14377
|
|
|
14322
|
-
var _templateObject$U, _templateObject2$v, _templateObject3$g, _templateObject4$6, _templateObject5$
|
|
14378
|
+
var _templateObject$U, _templateObject2$v, _templateObject3$g, _templateObject4$6, _templateObject5$3;
|
|
14323
14379
|
var html$R = String.raw;
|
|
14324
14380
|
var textWithImageHtml = function textWithImageHtml(_ref) {
|
|
14325
14381
|
var _ref$slide = _ref.slide,
|
|
@@ -14332,7 +14388,7 @@ var textWithImageHtml = function textWithImageHtml(_ref) {
|
|
|
14332
14388
|
var img = getImage(rawImg);
|
|
14333
14389
|
var imgUrl = escapeHtml(img);
|
|
14334
14390
|
var bg = escapeHtml(themeColors);
|
|
14335
|
-
return html$R(_templateObject3$g || (_templateObject3$g = _taggedTemplateLiteralLoose(["<div class=\"slide split\">\n <div class=\"slide-bg\" style=\"background-color:", "\"></div>\n <div class=\"split-inner\">\n <div class=\"right-image\" style=\"width:50%;\">\n <img src=\"", "\" alt=\"\" />\n </div>\n <div class=\"left-content\" style=\"width:50%;box-sizing:border-box;\">\n ", "\n ", "\n </div>\n </div>\n </div>"])), bg, imgUrl, slide.title ? html$R(_templateObject4$6 || (_templateObject4$6 = _taggedTemplateLiteralLoose(["<h2 class=\"title\" style=\"text-align:left;margin:0 0 12px;\">\n ", "\n </h2>"])), escapeHtml(slide.title)) : '', slide.text ? html$R(_templateObject5$
|
|
14391
|
+
return html$R(_templateObject3$g || (_templateObject3$g = _taggedTemplateLiteralLoose(["<div class=\"slide split\">\n <div class=\"slide-bg\" style=\"background-color:", "\"></div>\n <div class=\"split-inner\">\n <div class=\"right-image\" style=\"width:50%;\">\n <img src=\"", "\" alt=\"\" />\n </div>\n <div class=\"left-content\" style=\"width:50%;box-sizing:border-box;\">\n ", "\n ", "\n </div>\n </div>\n </div>"])), bg, imgUrl, slide.title ? html$R(_templateObject4$6 || (_templateObject4$6 = _taggedTemplateLiteralLoose(["<h2 class=\"title\" style=\"text-align:left;margin:0 0 12px;\">\n ", "\n </h2>"])), escapeHtml(slide.title)) : '', slide.text ? html$R(_templateObject5$3 || (_templateObject5$3 = _taggedTemplateLiteralLoose(["<p class=\"text\" style=\"text-align:left;margin:0;\">\n ", "\n </p>"])), escapeHtml(slide.text)) : '');
|
|
14336
14392
|
};
|
|
14337
14393
|
|
|
14338
14394
|
var _templateObject$V;
|
|
@@ -14350,7 +14406,7 @@ var presentationStyle = function presentationStyle(_ref) {
|
|
|
14350
14406
|
return html$S(_templateObject$V || (_templateObject$V = _taggedTemplateLiteralLoose(["\n <style>\n :root {\n --slide-width: 1600px;\n --slide-height: 900px;\n --rounded: 24px;\n --theme-bg: ", ";\n --theme-title-color: ", ";\n --theme-subtitle-color: ", ";\n --theme-text-color: ", ";\n --print-width: 29.7cm; /* A4 long side (landscape width) */\n --print-height: 21cm; /* A4 short side (landscape height) */\n }\n @page {\n size: var(--print-width) var(--print-height);\n margin: 0;\n }\n\n @media print {\n html,\n body {\n height: 100%;\n margin: 0 !important;\n padding: 0 !important;\n -webkit-transform: none !important;\n transform: none !important;\n }\n .slides-export {\n padding: 0 !important;\n margin: 0 !important;\n gap: 0 !important;\n align-items: stretch !important;\n display: block !important;\n }\n .slide {\n width: var(--print-width) !important;\n height: var(--print-height) !important;\n box-shadow: none !important;\n border-radius: 0 !important;\n overflow: hidden !important;\n margin: 0 !important;\n page-break-inside: avoid !important;\n break-inside: avoid !important;\n page-break-after: always !important;\n break-after: page !important;\n -webkit-transform: none !important;\n transform: none !important;\n }\n .slide + .slide {\n page-break-before: always !important;\n break-before: page !important;\n }\n .slide:first-child {\n page-break-before: auto !important;\n }\n .slide:last-child {\n page-break-after: auto !important;\n }\n .slide-bg {\n position: absolute !important;\n inset: 0 !important;\n width: 100% !important;\n height: 100% !important;\n }\n .slide img.slide-bg,\n .right-image img {\n width: 100% !important;\n height: 100% !important;\n object-fit: cover !important;\n display: block !important;\n }\n * {\n -webkit-print-color-adjust: exact;\n print-color-adjust: exact;\n }\n }\n body {\n background: var(--theme-bg);\n margin: 0;\n padding: 0;\n }\n .slides-export {\n font-family: ", ";\n padding: 40px;\n display: flex;\n flex-direction: column;\n gap: 32px;\n align-items: center;\n }\n .slide {\n position: relative;\n width: var(--slide-width);\n height: var(--slide-height);\n border-radius: var(--rounded);\n background: var(--theme-bg);\n box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);\n overflow: hidden;\n display: flex;\n flex-direction: column;\n page-break-inside: avoid;\n break-inside: avoid;\n page-break-after: always;\n break-after: page;\n -webkit-transform: none !important;\n transform: none !important;\n }\n .slide:last-child {\n page-break-after: auto;\n break-after: auto;\n }\n .slide.split {\n display: flex;\n }\n .split-inner {\n position: absolute;\n inset: 0;\n width: 100%;\n height: 100%;\n display: flex;\n }\n .cover-inner {\n position: relative;\n display: flex;\n flex-direction: column;\n width: 100%;\n height: 100%;\n z-index: 1;\n padding: 40px;\n }\n .cover-row {\n width: 100%;\n box-sizing: border-box;\n }\n .cover-center {\n flex: 1 1 auto;\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n }\n .cover-title {\n font-weight: 700;\n font-size: 48px;\n color: var(--theme-title-color);\n }\n .cover-subtitle {\n margin: 0;\n font-size: 20px;\n color: var(--theme-subtitle-color);\n }\n .left-content {\n flex: 1 1 50%;\n display: flex;\n flex-direction: column;\n justify-content: center;\n padding: 40px;\n box-sizing: border-box;\n z-index: 1;\n }\n .right-image {\n width: 50%;\n min-width: 0;\n background-position: center;\n background-size: cover;\n z-index: 0;\n }\n .right-image img {\n width: 100%;\n height: 100%;\n object-fit: cover;\n display: block;\n }\n .slide-bg {\n position: absolute;\n inset: 0;\n width: 100%;\n height: 100%;\n object-fit: cover;\n z-index: 0;\n }\n .content {\n position: relative;\n z-index: 1;\n height: 100%;\n width: 100%;\n box-sizing: border-box;\n padding: 40px;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n }\n .page-number {\n position: absolute;\n top: 12px;\n right: 16px;\n font-size: 14px;\n color: var(--theme-subtitle-color);\n background: rgba(255,255,255,0.0);\n padding: 4px 8px;\n border-radius: 6px;\n z-index: 3;\n pointer-events: none;\n }\n .slide--bullet .content {\n align-items: flex-start;\n }\n .slide--bullet .title,\n .slide--bullet .subtitle,\n .slide--bullet .text {\n align-self: start;\n text-align: left;\n }\n .slide--bullet .bullets-ul {\n margin-top: 48px;\n }\n .slide--process .content {\n align-items: flex-start;\n }\n .slide--process .title,\n .slide--process .subtitle,\n .slide--process .text {\n align-self: start;\n text-align: left;\n }\n .slide--process .bullets-ul {\n margin-top: 48px;\n }\n .title {\n font-weight: 700;\n font-size: 48px;\n margin: 0 0 8px;\n text-align: center;\n color: var(--theme-title-color);\n }\n .subtitle {\n font-weight: 500;\n font-size: 28px;\n margin: 0;\n text-align: center;\n color: var(--theme-subtitle-color);\n }\n .text {\n font-size: 20px;\n margin-top: 16px;\n text-align: center;\n color: var(--theme-text-color);\n }\n .bullets {\n padding-left: 24px;\n font-size: 20px;\n }\n .image-wrapper {\n display: flex;\n align-items: center;\n justify-content: center;\n height: 100%;\n }\n .image-wrapper img {\n max-width: 100%;\n max-height: 100%;\n object-fit: contain;\n }\n @media (max-width: 1200px) {\n :root {\n --slide-width: 960px;\n --slide-height: 540px;\n }\n }\n @media (max-width: 720px) {\n :root {\n --slide-width: 360px;\n --slide-height: 640px;\n }\n }\n </style>\n"])), theme.background, theme.title, theme.subtitle, theme.text, fontStack);
|
|
14351
14407
|
};
|
|
14352
14408
|
|
|
14353
|
-
var _templateObject$W, _templateObject2$w, _templateObject3$h, _templateObject4$7, _templateObject5$
|
|
14409
|
+
var _templateObject$W, _templateObject2$w, _templateObject3$h, _templateObject4$7, _templateObject5$4;
|
|
14354
14410
|
var htmlRaw$3 = String.raw;
|
|
14355
14411
|
var presentationHtml = function presentationHtml(_ref) {
|
|
14356
14412
|
var _ref$customizationSty = _ref.customizationStyle,
|
|
@@ -14405,8 +14461,8 @@ var presentationHtml = function presentationHtml(_ref) {
|
|
|
14405
14461
|
var fontLinkTags = fontLinks.map(function (href) {
|
|
14406
14462
|
return htmlRaw$3(_templateObject4$7 || (_templateObject4$7 = _taggedTemplateLiteralLoose(["<link rel=\"stylesheet\" href=\"", "\" />"])), href);
|
|
14407
14463
|
}).join('');
|
|
14408
|
-
return htmlRaw$3(_templateObject5$
|
|
14464
|
+
return htmlRaw$3(_templateObject5$4 || (_templateObject5$4 = _taggedTemplateLiteralLoose(["<!DOCTYPE html>\n <html>\n <head>\n <meta charset=\"UTF-8\" />\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\" />\n ", "\n ", "\n </head>\n <body>\n <div class=\"slides-export\">\n ", "\n </div>\n </body>\n </html>"])), fontLinkTags, css, innerContent);
|
|
14409
14465
|
};
|
|
14410
14466
|
|
|
14411
|
-
export { contractHtml as ContractHtml, InvoiceCompatHtml, InvoiceCompatHtml$1 as InvoiceCompatJapanHtml, invoiceHtml as InvoiceHtml, invoiceHtml$1 as InvoiceJapanHtml, presentationHtml as PresentationHtml,
|
|
14467
|
+
export { contractHtml as ContractHtml, InvoiceCompatHtml, InvoiceCompatHtml$1 as InvoiceCompatJapanHtml, invoiceHtml as InvoiceHtml, invoiceHtml$1 as InvoiceJapanHtml, presentationHtml as PresentationHtml, SubscriptionInvoiceHtml, renderOldLayout as invoiceHtmlWithDetails, renderNewLayout as invoiceHtmlWithDetailsNew, renderLayout as invoiceJapanHtmlWithDetails, renderLayout as renderJapanInvoice, renderNewLayout as renderNewInvoice, renderOldLayout as renderOldInvoice };
|
|
14412
14468
|
//# sourceMappingURL=index.modern.js.map
|