lm-web-controls 1.4.39 → 1.4.41
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.
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import e,{useState as t,useEffect as a}from"react";import{toast as n}from"react-toastify";function
|
|
2
|
+
import e,{useState as t,useEffect as a}from"react";import{toast as n}from"react-toastify";function l(l){var i,r,o=l.job,c=l.backLink,m=void 0===c?"/careers":c,s=l.backText,d=void 0===s?"← Back to Careers":s,u=l.contactEmail,y=void 0===u?"hr@company.com":u,p=l.showEmailLink,h=void 0!==p&&p,b=l.companyName,E=void 0===b?"Company":b,v=l.primaryColor,g=l.shareUrl,f=l.onApplyClick,j=l.icons,x=l.classNames,k=void 0===x?{}:x,N=t(""),w=N[0],q=N[1],S=function(e,t){return t||e},I=function(){g&&navigator.clipboard.writeText(g).then(function(){n.success("Job URL copied to clipboard!")}).catch(function(){window.open("data:text/plain,".concat(g),"_blank"),n.info("Job URL opened in new window for copying")})},C=v?{"--job-detail-primary":v}:void 0;return a(function(){"undefined"!=typeof window&&q(window.location.origin)},[]),a(function(){var e;if(w){var t={"@context":"https://schema.org","@type":"JobPosting",title:o.title,description:o.description,datePosted:new Date(o.createdOn).toISOString(),validThrough:o.closingDate?new Date(o.closingDate).toISOString():void 0,employmentType:null===(e=o.employmentType)||void 0===e?void 0:e.toUpperCase(),hiringOrganization:{"@type":"Organization",name:E},jobLocation:{"@type":"Place",address:{"@type":"PostalAddress",addressLocality:o.location.city,addressRegion:o.location.state,addressCountry:o.location.country}},baseSalary:o.salary&&o.salary.min&&o.salary.max&&o.salary.currency?{"@type":"MonetaryAmount",currency:o.salary.currency,value:{"@type":"MonetaryAmountDistribution",minValue:o.salary.min,maxValue:o.salary.max}}:void 0,identifier:{"@type":"PropertyValue",name:"Job ID",value:o.id}},a=document.getElementById("job-posting-json-ld-schema");a&&document.head.removeChild(a);var n=document.createElement("script");return n.type="application/ld+json",n.id="job-posting-json-ld-schema",n.innerHTML=JSON.stringify(t),document.head.appendChild(n),function(){document.head.contains(n)&&document.head.removeChild(n)}}},[w,o]),e.createElement("section",{className:S("job-detail-container",k.container),style:C},e.createElement("div",{className:S("job-detail-navigation-bar",k.navigationBar)},e.createElement("a",{href:m,className:S("job-detail-back-button",k.backButton)},(null==j?void 0:j.back)?j.back:e.createElement("svg",{width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2"},e.createElement("line",{x1:"19",y1:"12",x2:"5",y2:"12"}),e.createElement("polyline",{points:"12 19 5 12 12 5"})),e.createElement("span",null,d)),g&&e.createElement("button",{onClick:function(){g&&(navigator.share?navigator.share({title:o.title,text:"Check out this job opportunity: ".concat(o.title," at ").concat(E),url:g}).then(function(){n.success("Job shared successfully!")}).catch(function(){I()}):I())},className:S("job-detail-share-button",k.shareButton),title:"Share this job"},(null==j?void 0:j.share)?j.share:e.createElement("svg",{width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2"},e.createElement("circle",{cx:"18",cy:"5",r:"3"}),e.createElement("circle",{cx:"6",cy:"12",r:"3"}),e.createElement("circle",{cx:"18",cy:"19",r:"3"}),e.createElement("line",{x1:"8.59",y1:"13.51",x2:"15.42",y2:"17.49"}),e.createElement("line",{x1:"15.41",y1:"6.51",x2:"8.59",y2:"10.49"})))),e.createElement("div",{className:S("job-detail-header",k.header)},e.createElement("h1",{className:S("job-detail-title",k.title)},o.title),e.createElement("div",{className:S("job-detail-meta-info",k.metaInfo)},e.createElement("div",{className:S("job-meta-item",k.metaItem)},(null==j?void 0:j.location)?e.createElement("span",{className:S("job-meta-icon",k.metaIcon)},j.location):e.createElement("svg",{className:S("job-meta-icon",k.metaIcon),width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2"},e.createElement("path",{d:"M21 10c0 7-9 13-9 13s-9-6-9-13a9 9 0 0 1 18 0z"}),e.createElement("circle",{cx:"12",cy:"10",r:"3"})),e.createElement("span",null,"Location: ",(i=o.location,r=[i.city,i.country].filter(Boolean).join(", "),i.remote?r+=" (Remote)":i.hybrid&&(r+=" (Hybrid)"),r))),o.employmentType?e.createElement("div",{className:S("job-meta-item",k.metaItem)},(null==j?void 0:j.type)?e.createElement("span",{className:S("job-meta-icon",k.metaIcon)},j.type):e.createElement("svg",{className:S("job-meta-icon",k.metaIcon),width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2"},e.createElement("rect",{x:"2",y:"7",width:"20",height:"14",rx:"2",ry:"2"}),e.createElement("path",{d:"M16 21V5a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16"})),e.createElement("span",null,"Job Type: ",o.employmentType)):null,o.department?e.createElement("div",{className:S("job-meta-item",k.metaItem)},e.createElement("span",null,"Department: ",o.department)):null,o.salary&&o.salary.min&&o.salary.max&&o.salary.currency?e.createElement("div",{className:S("job-meta-item",k.metaItem)},e.createElement("span",null,"Salary: ",o.salary.currency," ",o.salary.min.toLocaleString()," ","- ",o.salary.max.toLocaleString())):null,o.closingDate?e.createElement("div",{className:S("job-meta-item",k.metaItem)},(null==j?void 0:j.calendar)?e.createElement("span",{className:S("job-meta-icon",k.metaIcon)},j.calendar):e.createElement("svg",{className:S("job-meta-icon",k.metaIcon),width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2"},e.createElement("rect",{x:"3",y:"4",width:"18",height:"18",rx:"2",ry:"2"}),e.createElement("line",{x1:"16",y1:"2",x2:"16",y2:"6"}),e.createElement("line",{x1:"8",y1:"2",x2:"8",y2:"6"}),e.createElement("line",{x1:"3",y1:"10",x2:"21",y2:"10"})),e.createElement("span",null,"Apply by: ",new Date(o.closingDate).toLocaleDateString())):null,o.numberOfPositions?e.createElement("div",{className:S("job-meta-item",k.metaItem)},e.createElement("span",null,"Positions: ",o.numberOfPositions)):null)),e.createElement("div",{className:S("job-detail-description",k.description),dangerouslySetInnerHTML:{__html:o.description}}),o.requirements?e.createElement("div",{className:S("job-detail-requirements",k.requirements)},e.createElement("h3",null,"Requirements"),o.requirements.experience?e.createElement("div",{className:"requirement-item"},e.createElement("strong",null,"Experience:")," ",o.requirements.experience):null,o.requirements.education?e.createElement("div",{className:"requirement-item"},e.createElement("strong",null,"Education:")," ",o.requirements.education):null,o.requirements.requiredSkills&&o.requirements.requiredSkills.length>0?e.createElement("div",{className:"requirement-item"},e.createElement("strong",null,"Required Skills:")," ",o.requirements.requiredSkills.join(", ")):null,o.requirements.preferredSkills&&o.requirements.preferredSkills.length>0?e.createElement("div",{className:"requirement-item"},e.createElement("strong",null,"Preferred Skills:")," ",o.requirements.preferredSkills.join(", ")):null):null,e.createElement("div",{className:S("job-detail-cta",k.ctaContainer)},f&&!h&&e.createElement("button",{className:S("job-detail-apply-button",k.applyButton),onClick:f},"Apply Now"),y?e.createElement("div",{className:S("job-detail-email-section",k.emailSection)},e.createElement("p",{className:S("job-detail-email-label",k.emailLabel)},"Prefer email?"),e.createElement("a",{href:"mailto:".concat(y,"?subject=Application for ").concat(o.title,"&body=Hi, I am interested in applying for the ").concat(o.title," position."),className:S("job-detail-email-link",k.emailLink)},y)):null))}export{l as JobDetail};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import e from"react";import{toast as t}from"react-toastify";function a(a){var o=a.jobs,l=a.title,n=void 0===l?"We are hiring...":l,c=a.subtitle,r=a.nestedUrl,i=a.emptyMessage,s=void 0===i?"No open positions at the moment. Check back soon!":i,m=a.showGeneralApply,d=void 0!==m&&m,p=a.generalApplyText,
|
|
2
|
+
import e from"react";import{toast as t}from"react-toastify";function a(a){var o=a.jobs,l=a.title,n=void 0===l?"We are hiring...":l,c=a.subtitle,r=a.nestedUrl,i=a.emptyMessage,s=void 0===i?"No open positions at the moment. Check back soon!":i,m=a.showGeneralApply,d=void 0!==m&&m,p=a.generalApplyText,u=void 0===p?"Didn't find a match? Submit your resume for future opportunities":p,b=a.generalApplyButtonText,y=void 0===b?"Submit Your Resume":b,h=a.contactEmail,E=a.primaryColor,j=a.companyName,v=void 0===j?"Company":j,N=a.shareUrlTemplate,f=a.icons,g=a.classNames,w=void 0===g?{}:g,x=function(e,t){return t||e},k=E?{"--job-primary-color":E}:void 0,C=function(e){navigator.clipboard.writeText(e).then(function(){t.success("Job URL copied to clipboard!")}).catch(function(){window.open("data:text/plain,".concat(e),"_blank"),t.info("Job URL opened in new window for copying")})};return e.createElement("section",{className:x("job-list-container",w.container),style:k},n&&e.createElement("div",{className:x("job-list-header",w.header)},e.createElement("h2",{className:x("job-list-title",w.title)},n),c?e.createElement("p",{className:x("job-list-subtitle",w.subtitle)},c):null),o.length>0?e.createElement("div",{className:x("job-list-grid",w.jobsGrid)},o.map(function(a){return e.createElement("div",{key:a.id,className:x("job-card",w.jobCard)},e.createElement("div",{className:"job-card-content"},e.createElement("div",{className:x("job-card-header",w.jobCardHeader)},e.createElement("h3",{className:x("job-card-title",w.jobTitle)},a.title),N&&e.createElement("button",{onClick:function(){return function(e){if(N){var a=N.replace("{slug}",e.slug);navigator.share?navigator.share({title:e.title,text:"Check out this job opportunity: ".concat(e.title," at ").concat(v),url:a}).then(function(){t.success("Job shared successfully!")}).catch(function(){C(a)}):C(a)}}(a)},className:x("job-card-share-button",w.shareButton),title:"Share this job"},(null==f?void 0:f.share)?f.share:e.createElement("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2"},e.createElement("circle",{cx:"18",cy:"5",r:"3"}),e.createElement("circle",{cx:"6",cy:"12",r:"3"}),e.createElement("circle",{cx:"18",cy:"19",r:"3"}),e.createElement("line",{x1:"8.59",y1:"13.51",x2:"15.42",y2:"17.49"}),e.createElement("line",{x1:"15.41",y1:"6.51",x2:"8.59",y2:"10.49"})))),e.createElement("div",{className:"job-card-details"},e.createElement("div",{className:x("job-card-location",w.jobLocation)},(null==f?void 0:f.location)?e.createElement("span",{className:x("job-card-icon",w.locationIcon)},f.location):e.createElement("svg",{className:x("job-card-icon",w.locationIcon),width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2"},e.createElement("path",{d:"M21 10c0 7-9 13-9 13s-9-6-9-13a9 9 0 0 1 18 0z"}),e.createElement("circle",{cx:"12",cy:"10",r:"3"})),e.createElement("span",null,(o=a.location,l=[o.city,o.country].filter(Boolean).join(", "),o.remote?l+=" (Remote)":o.hybrid&&(l+=" (Hybrid)"),l))),a.employmentType&&e.createElement("div",{className:x("job-card-type",w.jobType)},(null==f?void 0:f.type)?e.createElement("span",{className:x("job-card-icon",w.typeIcon)},f.type):e.createElement("svg",{className:x("job-card-icon",w.typeIcon),width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2"},e.createElement("rect",{x:"2",y:"7",width:"20",height:"14",rx:"2",ry:"2"}),e.createElement("path",{d:"M16 21V5a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16"})),e.createElement("span",null,a.employmentType)))),e.createElement("div",{className:x("job-card-actions",w.jobCardActions)},e.createElement("a",{href:"".concat(r?"/".concat(r):"","/openings/").concat(a.slug),className:x("job-card-button",w.viewButton)},"View/Apply",(null==f?void 0:f.arrow)?e.createElement("span",{className:x("job-card-arrow",w.arrowIcon)},f.arrow):e.createElement("svg",{className:x("job-card-arrow",w.arrowIcon),width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2"},e.createElement("line",{x1:"5",y1:"12",x2:"19",y2:"12"}),e.createElement("polyline",{points:"12 5 19 12 12 19"})))));var o,l})):e.createElement("div",{className:x("job-list-empty",w.emptyState)},e.createElement("p",null,s)),d&&e.createElement("div",{className:x("job-list-general-apply",w.generalApplySection)},e.createElement("p",{className:x("job-list-general-apply-text",w.generalApplyText)},u),e.createElement("button",{"data-career-apply":!0,className:x("job-list-general-apply-button",w.generalApplyButton)},y)),h&&e.createElement("div",{className:x("job-list-email-section",w.emailSection)},e.createElement("p",{className:x("job-list-email-label",w.emailLabel)},"Prefer email?"),e.createElement("a",{href:"mailto:".concat(h,"?subject=General Application&body=Hi, I am interested in submitting my resume for future opportunities."),className:x("job-list-email-link",w.emailLink)},h)))}export{a as JobList};
|
package/package.json
CHANGED
|
@@ -363,16 +363,16 @@ declare module "lm-web-controls" {
|
|
|
363
363
|
};
|
|
364
364
|
|
|
365
365
|
type JobSalary = {
|
|
366
|
-
min: number;
|
|
367
|
-
max: number;
|
|
368
|
-
currency: string;
|
|
366
|
+
min: number | null;
|
|
367
|
+
max: number | null;
|
|
368
|
+
currency: string | null;
|
|
369
369
|
};
|
|
370
370
|
|
|
371
371
|
type JobRequirements = {
|
|
372
|
-
experience: string;
|
|
373
|
-
education: string;
|
|
374
|
-
requiredSkills: string[];
|
|
375
|
-
preferredSkills: string[];
|
|
372
|
+
experience: string | null;
|
|
373
|
+
education: string | null;
|
|
374
|
+
requiredSkills: string[] | null;
|
|
375
|
+
preferredSkills: string[] | null;
|
|
376
376
|
};
|
|
377
377
|
|
|
378
378
|
type HiringManager = {
|
|
@@ -393,20 +393,20 @@ declare module "lm-web-controls" {
|
|
|
393
393
|
slug: string;
|
|
394
394
|
description: string;
|
|
395
395
|
category: JobCategory;
|
|
396
|
-
department
|
|
397
|
-
employmentType
|
|
396
|
+
department?: string;
|
|
397
|
+
employmentType?: string;
|
|
398
398
|
location: JobLocation;
|
|
399
|
-
salary
|
|
400
|
-
requirements
|
|
399
|
+
salary?: JobSalary;
|
|
400
|
+
requirements?: JobRequirements;
|
|
401
401
|
status: string;
|
|
402
|
-
numberOfPositions
|
|
403
|
-
closingDate
|
|
404
|
-
hiringManager
|
|
405
|
-
stats
|
|
402
|
+
numberOfPositions?: number;
|
|
403
|
+
closingDate?: Date | null;
|
|
404
|
+
hiringManager?: HiringManager;
|
|
405
|
+
stats?: JobStats;
|
|
406
406
|
isActive: boolean;
|
|
407
407
|
tenantId: string;
|
|
408
|
-
createdOn:
|
|
409
|
-
updatedOn
|
|
408
|
+
createdOn: Date;
|
|
409
|
+
updatedOn?: Date | null;
|
|
410
410
|
};
|
|
411
411
|
|
|
412
412
|
type JobListProps = {
|
|
@@ -420,10 +420,13 @@ declare module "lm-web-controls" {
|
|
|
420
420
|
generalApplyButtonText?: string;
|
|
421
421
|
contactEmail?: string;
|
|
422
422
|
primaryColor?: string;
|
|
423
|
+
companyName?: string;
|
|
424
|
+
shareUrlTemplate?: string;
|
|
423
425
|
icons?: {
|
|
424
426
|
location?: ReactNode;
|
|
425
427
|
type?: ReactNode;
|
|
426
428
|
arrow?: ReactNode;
|
|
429
|
+
share?: ReactNode;
|
|
427
430
|
};
|
|
428
431
|
classNames?: {
|
|
429
432
|
container?: string;
|
|
@@ -432,9 +435,12 @@ declare module "lm-web-controls" {
|
|
|
432
435
|
subtitle?: string;
|
|
433
436
|
jobsGrid?: string;
|
|
434
437
|
jobCard?: string;
|
|
438
|
+
jobCardHeader?: string;
|
|
435
439
|
jobTitle?: string;
|
|
436
440
|
jobLocation?: string;
|
|
437
441
|
jobType?: string;
|
|
442
|
+
jobCardActions?: string;
|
|
443
|
+
shareButton?: string;
|
|
438
444
|
viewButton?: string;
|
|
439
445
|
emptyState?: string;
|
|
440
446
|
locationIcon?: string;
|
|
@@ -457,28 +463,33 @@ declare module "lm-web-controls" {
|
|
|
457
463
|
showEmailLink?: boolean;
|
|
458
464
|
companyName?: string;
|
|
459
465
|
primaryColor?: string;
|
|
466
|
+
shareUrl?: string;
|
|
460
467
|
onApplyClick?: () => void;
|
|
468
|
+
icons?: {
|
|
469
|
+
location?: ReactNode;
|
|
470
|
+
type?: ReactNode;
|
|
471
|
+
calendar?: ReactNode;
|
|
472
|
+
back?: ReactNode;
|
|
473
|
+
share?: ReactNode;
|
|
474
|
+
};
|
|
461
475
|
classNames?: {
|
|
462
476
|
container?: string;
|
|
463
477
|
backButton?: string;
|
|
478
|
+
navigationBar?: string;
|
|
479
|
+
shareButton?: string;
|
|
464
480
|
header?: string;
|
|
465
481
|
title?: string;
|
|
466
482
|
metaInfo?: string;
|
|
467
483
|
metaItem?: string;
|
|
468
484
|
metaIcon?: string;
|
|
485
|
+
description?: string;
|
|
486
|
+
requirements?: string;
|
|
469
487
|
applyButton?: string;
|
|
470
488
|
ctaContainer?: string;
|
|
471
|
-
description?: string;
|
|
472
489
|
emailSection?: string;
|
|
473
490
|
emailLabel?: string;
|
|
474
491
|
emailLink?: string;
|
|
475
492
|
};
|
|
476
|
-
icons?: {
|
|
477
|
-
location?: ReactNode;
|
|
478
|
-
type?: ReactNode;
|
|
479
|
-
calendar?: ReactNode;
|
|
480
|
-
back?: ReactNode;
|
|
481
|
-
};
|
|
482
493
|
};
|
|
483
494
|
|
|
484
495
|
type CareerApplicationFormProps = {
|