@apps-in-toss/web-bridge 2.5.1 → 2.5.2
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.cjs +10 -0
- package/dist/index.js +10 -0
- package/package.json +4 -4
package/dist/index.cjs
CHANGED
|
@@ -1287,6 +1287,7 @@ var DEFAULT_ATTACH_VARIANT = "expanded";
|
|
|
1287
1287
|
var ATTACH_CLASS_NAME = "toss-ads-attach";
|
|
1288
1288
|
var ATTACH_STYLE_ID = "toss-ads-attach-style";
|
|
1289
1289
|
var ATTACH_WRAPPER_ATTRIBUTE = "data-toss-ads-attach-banner-wrapper";
|
|
1290
|
+
var ATTACH_AD_FONT_FAMILY = '"Toss Product Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", sans-serif';
|
|
1290
1291
|
function ensureAttachStyles(container) {
|
|
1291
1292
|
const documentRef = container.ownerDocument;
|
|
1292
1293
|
if (!documentRef) {
|
|
@@ -1298,6 +1299,11 @@ function ensureAttachStyles(container) {
|
|
|
1298
1299
|
const style = documentRef.createElement("style");
|
|
1299
1300
|
style.id = ATTACH_STYLE_ID;
|
|
1300
1301
|
style.textContent = `
|
|
1302
|
+
.${ATTACH_CLASS_NAME},
|
|
1303
|
+
.${ATTACH_CLASS_NAME} * {
|
|
1304
|
+
font-family: ${ATTACH_AD_FONT_FAMILY};
|
|
1305
|
+
font-style: normal;
|
|
1306
|
+
}
|
|
1301
1307
|
.${ATTACH_CLASS_NAME} { background: #ffffff; }
|
|
1302
1308
|
.${ATTACH_CLASS_NAME}.toss-ads-tone-grey { background: #f2f4f7; }
|
|
1303
1309
|
@media (prefers-color-scheme: dark) {
|
|
@@ -1363,6 +1369,8 @@ function attachBanner(adGroupId, target, options = {}) {
|
|
|
1363
1369
|
wrapper.style.boxSizing = "border-box";
|
|
1364
1370
|
wrapper.style.display = "flex";
|
|
1365
1371
|
wrapper.style.flexDirection = "column";
|
|
1372
|
+
wrapper.style.fontFamily = ATTACH_AD_FONT_FAMILY;
|
|
1373
|
+
wrapper.style.fontStyle = "normal";
|
|
1366
1374
|
wrapper.style.justifyContent = "center";
|
|
1367
1375
|
wrapper.style.overflow = "hidden";
|
|
1368
1376
|
wrapper.setAttribute(ATTACH_WRAPPER_ATTRIBUTE, "true");
|
|
@@ -1371,6 +1379,8 @@ function attachBanner(adGroupId, target, options = {}) {
|
|
|
1371
1379
|
}
|
|
1372
1380
|
const element = document.createElement("div");
|
|
1373
1381
|
element.classList.add(ATTACH_CLASS_NAME);
|
|
1382
|
+
element.style.fontFamily = ATTACH_AD_FONT_FAMILY;
|
|
1383
|
+
element.style.fontStyle = "normal";
|
|
1374
1384
|
if (tone === "grey") {
|
|
1375
1385
|
element.classList.add("toss-ads-tone-grey");
|
|
1376
1386
|
}
|
package/dist/index.js
CHANGED
|
@@ -1238,6 +1238,7 @@ var DEFAULT_ATTACH_VARIANT = "expanded";
|
|
|
1238
1238
|
var ATTACH_CLASS_NAME = "toss-ads-attach";
|
|
1239
1239
|
var ATTACH_STYLE_ID = "toss-ads-attach-style";
|
|
1240
1240
|
var ATTACH_WRAPPER_ATTRIBUTE = "data-toss-ads-attach-banner-wrapper";
|
|
1241
|
+
var ATTACH_AD_FONT_FAMILY = '"Toss Product Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", sans-serif';
|
|
1241
1242
|
function ensureAttachStyles(container) {
|
|
1242
1243
|
const documentRef = container.ownerDocument;
|
|
1243
1244
|
if (!documentRef) {
|
|
@@ -1249,6 +1250,11 @@ function ensureAttachStyles(container) {
|
|
|
1249
1250
|
const style = documentRef.createElement("style");
|
|
1250
1251
|
style.id = ATTACH_STYLE_ID;
|
|
1251
1252
|
style.textContent = `
|
|
1253
|
+
.${ATTACH_CLASS_NAME},
|
|
1254
|
+
.${ATTACH_CLASS_NAME} * {
|
|
1255
|
+
font-family: ${ATTACH_AD_FONT_FAMILY};
|
|
1256
|
+
font-style: normal;
|
|
1257
|
+
}
|
|
1252
1258
|
.${ATTACH_CLASS_NAME} { background: #ffffff; }
|
|
1253
1259
|
.${ATTACH_CLASS_NAME}.toss-ads-tone-grey { background: #f2f4f7; }
|
|
1254
1260
|
@media (prefers-color-scheme: dark) {
|
|
@@ -1314,6 +1320,8 @@ function attachBanner(adGroupId, target, options = {}) {
|
|
|
1314
1320
|
wrapper.style.boxSizing = "border-box";
|
|
1315
1321
|
wrapper.style.display = "flex";
|
|
1316
1322
|
wrapper.style.flexDirection = "column";
|
|
1323
|
+
wrapper.style.fontFamily = ATTACH_AD_FONT_FAMILY;
|
|
1324
|
+
wrapper.style.fontStyle = "normal";
|
|
1317
1325
|
wrapper.style.justifyContent = "center";
|
|
1318
1326
|
wrapper.style.overflow = "hidden";
|
|
1319
1327
|
wrapper.setAttribute(ATTACH_WRAPPER_ATTRIBUTE, "true");
|
|
@@ -1322,6 +1330,8 @@ function attachBanner(adGroupId, target, options = {}) {
|
|
|
1322
1330
|
}
|
|
1323
1331
|
const element = document.createElement("div");
|
|
1324
1332
|
element.classList.add(ATTACH_CLASS_NAME);
|
|
1333
|
+
element.style.fontFamily = ATTACH_AD_FONT_FAMILY;
|
|
1334
|
+
element.style.fontStyle = "normal";
|
|
1325
1335
|
if (tone === "grey") {
|
|
1326
1336
|
element.classList.add("toss-ads-tone-grey");
|
|
1327
1337
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@apps-in-toss/web-bridge",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "2.5.
|
|
4
|
+
"version": "2.5.2",
|
|
5
5
|
"description": "Web Bridge for Apps In Toss",
|
|
6
6
|
"scripts": {
|
|
7
7
|
"typecheck": "tsc --noEmit",
|
|
@@ -27,11 +27,11 @@
|
|
|
27
27
|
"dist"
|
|
28
28
|
],
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@apps-in-toss/types": "2.5.
|
|
30
|
+
"@apps-in-toss/types": "2.5.2"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
|
-
"@apps-in-toss/bridge-core": "2.5.
|
|
34
|
-
"@apps-in-toss/native-modules": "^2.5.
|
|
33
|
+
"@apps-in-toss/bridge-core": "2.5.2",
|
|
34
|
+
"@apps-in-toss/native-modules": "^2.5.2",
|
|
35
35
|
"@swc/core": "^1.12.7",
|
|
36
36
|
"picocolors": "^1.1.1",
|
|
37
37
|
"ts-morph": "^26.0.0",
|