diff --git a/blocks/agent-transactions/agent-transactions.css b/blocks/agent-transactions/agent-transactions.css index 061fc67c..c7e43f8c 100644 --- a/blocks/agent-transactions/agent-transactions.css +++ b/blocks/agent-transactions/agent-transactions.css @@ -1,3 +1,5 @@ +@import url('./design-1.css'); + .agent-transactions.block table { width: 100%; font-size: var(--body-font-size-s); diff --git a/blocks/agent-transactions/agent-transactions.js b/blocks/agent-transactions/agent-transactions.js index dea0f63b..ca365caf 100644 --- a/blocks/agent-transactions/agent-transactions.js +++ b/blocks/agent-transactions/agent-transactions.js @@ -11,7 +11,7 @@ const getClosedTransactions = async () => { const response = await fetch(`/bin/bhhs/agentPropertyListingsServlet.${agentId}.json`); const data = await response.json(); - if (data && data?.closedTransactions?.properties?.length) { + if (data?.closedTransactions?.properties?.length) { data.closedTransactions.properties.forEach((property) => { formattedData.push({ address: property.StreetName, diff --git a/blocks/agent-transactions/design-1.css b/blocks/agent-transactions/design-1.css new file mode 100644 index 00000000..f37a148e --- /dev/null +++ b/blocks/agent-transactions/design-1.css @@ -0,0 +1,42 @@ +.design-1 .agent-transactions.block h1 { + font-family: var(--font-family-secondary); + font-size: 1.75rem; + font-weight: var(--font-weight-normal); + text-align: center; +} + +.design-1 .agent-transactions.block th { + color: var(--white); +} + +@media (min-width: 600px) { + .design-1 .agent-transactions.block h1 { + font-size: 2.25rem; + } +} + +@media (min-width: 1200px) { + .design-1 .agent-transactions.block h1 { + font-size: 2.75rem; + } +} + +/* +---------------------------------------- +* Theme Name: Traditional +*/ +.design-1.traditional .agent-transactions.block thead { + background: var(--primary-color); +} + +/* +---------------------------------------- +* Theme Name: Black & White +*/ +.design-1.black-white .agent-transactions.block h1 { + color: var(--black); +} + +.design-1.black-white .agent-transactions.block thead { + background: var(--black); +}