@prodigio-io/sdk 2.1.3 → 2.1.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 +9 -4
- package/dist/index.mjs +9 -4
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -95,16 +95,20 @@ var BADGE_ELEMENT_ID = "prodigio-badge-widget";
|
|
|
95
95
|
function injectBadge(_position) {
|
|
96
96
|
if (typeof document === "undefined") return;
|
|
97
97
|
if (document.getElementById(BADGE_ELEMENT_ID)) return;
|
|
98
|
+
const wrapper = document.createElement("div");
|
|
99
|
+
wrapper.id = BADGE_ELEMENT_ID;
|
|
100
|
+
wrapper.style.cssText = `
|
|
101
|
+
width: 100%; display: flex; justify-content: flex-end;
|
|
102
|
+
padding: 16px 20px; box-sizing: border-box;
|
|
103
|
+
`;
|
|
98
104
|
const el = document.createElement("a");
|
|
99
|
-
el.id = BADGE_ELEMENT_ID;
|
|
100
105
|
el.href = "https://prodigio.io";
|
|
101
106
|
el.target = "_blank";
|
|
102
107
|
el.rel = "noopener noreferrer";
|
|
103
108
|
el.setAttribute("data-prodigio-badge", "true");
|
|
104
109
|
el.setAttribute("aria-label", "Hiring powered by Prodigio");
|
|
105
110
|
el.style.cssText = `
|
|
106
|
-
|
|
107
|
-
z-index: 2147483647; display: inline-flex; align-items: center; gap: 7px;
|
|
111
|
+
display: inline-flex; align-items: center; gap: 7px;
|
|
108
112
|
padding: 7px 14px; background: #ffffff; border: 1px solid #e5e5e5;
|
|
109
113
|
border-radius: 24px; box-shadow: 0 2px 8px rgba(0,0,0,0.08);
|
|
110
114
|
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
|
@@ -129,7 +133,8 @@ function injectBadge(_position) {
|
|
|
129
133
|
el.addEventListener("mouseleave", () => {
|
|
130
134
|
el.style.boxShadow = "0 2px 8px rgba(0,0,0,0.08)";
|
|
131
135
|
});
|
|
132
|
-
|
|
136
|
+
wrapper.appendChild(el);
|
|
137
|
+
document.body.appendChild(wrapper);
|
|
133
138
|
}
|
|
134
139
|
function removeBadge() {
|
|
135
140
|
var _a;
|
package/dist/index.mjs
CHANGED
|
@@ -69,16 +69,20 @@ var BADGE_ELEMENT_ID = "prodigio-badge-widget";
|
|
|
69
69
|
function injectBadge(_position) {
|
|
70
70
|
if (typeof document === "undefined") return;
|
|
71
71
|
if (document.getElementById(BADGE_ELEMENT_ID)) return;
|
|
72
|
+
const wrapper = document.createElement("div");
|
|
73
|
+
wrapper.id = BADGE_ELEMENT_ID;
|
|
74
|
+
wrapper.style.cssText = `
|
|
75
|
+
width: 100%; display: flex; justify-content: flex-end;
|
|
76
|
+
padding: 16px 20px; box-sizing: border-box;
|
|
77
|
+
`;
|
|
72
78
|
const el = document.createElement("a");
|
|
73
|
-
el.id = BADGE_ELEMENT_ID;
|
|
74
79
|
el.href = "https://prodigio.io";
|
|
75
80
|
el.target = "_blank";
|
|
76
81
|
el.rel = "noopener noreferrer";
|
|
77
82
|
el.setAttribute("data-prodigio-badge", "true");
|
|
78
83
|
el.setAttribute("aria-label", "Hiring powered by Prodigio");
|
|
79
84
|
el.style.cssText = `
|
|
80
|
-
|
|
81
|
-
z-index: 2147483647; display: inline-flex; align-items: center; gap: 7px;
|
|
85
|
+
display: inline-flex; align-items: center; gap: 7px;
|
|
82
86
|
padding: 7px 14px; background: #ffffff; border: 1px solid #e5e5e5;
|
|
83
87
|
border-radius: 24px; box-shadow: 0 2px 8px rgba(0,0,0,0.08);
|
|
84
88
|
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
|
@@ -103,7 +107,8 @@ function injectBadge(_position) {
|
|
|
103
107
|
el.addEventListener("mouseleave", () => {
|
|
104
108
|
el.style.boxShadow = "0 2px 8px rgba(0,0,0,0.08)";
|
|
105
109
|
});
|
|
106
|
-
|
|
110
|
+
wrapper.appendChild(el);
|
|
111
|
+
document.body.appendChild(wrapper);
|
|
107
112
|
}
|
|
108
113
|
function removeBadge() {
|
|
109
114
|
var _a;
|