Skip to content

Commit

Permalink
Merge pull request #271 from Shinsina/master-10-18-2023
Browse files Browse the repository at this point in the history
Separate master copy branch to unify the staging and master branches
  • Loading branch information
Shinsina authored Oct 18, 2023
2 parents 3c528d0 + ca27045 commit d6a67ac
Show file tree
Hide file tree
Showing 24 changed files with 246 additions and 190 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/deploy-production.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,15 @@ jobs:

post-deploy-failure:
if: failure()
needs: [notify-start, deploy-sites]
needs: [notify-start, build-sites, deploy-sites]
uses: parameter1/actions/.github/workflows/notify-fail.yml@main
secrets: inherit
with:
slack-thread: ${{ needs.notify-start.outputs.slack-thread }}

post-deploy-complete:
if: success()
needs: [notify-start, deploy-sites]
needs: [notify-start, build-sites, deploy-sites]
uses: parameter1/actions/.github/workflows/notify-complete.yml@main
secrets: inherit
with:
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/deploy-staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,15 @@ jobs:

post-deploy-failure:
if: failure()
needs: [notify-start, deploy-sites]
needs: [notify-start, build-sites, deploy-sites]
uses: parameter1/actions/.github/workflows/notify-fail.yml@main
secrets: inherit
with:
slack-thread: ${{ needs.notify-start.outputs.slack-thread }}

post-deploy-complete:
if: success()
needs: [notify-start, deploy-sites]
needs: [notify-start, build-sites, deploy-sites]
uses: parameter1/actions/.github/workflows/notify-complete.yml@main
secrets: inherit
with:
Expand All @@ -53,9 +53,9 @@ jobs:
###############################################
site:
- { dir: ccnewsnow.com, stack: virgon, id: 60c28bc3d28860bc334ebcb2, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-ccnewsnow.com }
- { dir: diverseeducation.com, stack: virgon, id: 60c281c6d28860bc33464ae0, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-diverseeducation.com }
- { dir: diversemilitary.net, stack: virgon, id: 60c28c0dd28860bc334ed723, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-diversemilitary.net }
- { dir: divhealth.net, stack: virgon, id: 60c28c4bd28860bc334f485d, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-divhealth.net }
- { dir: diverseeducation.com, stack: leonis, id: 60c281c6d28860bc33464ae0, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-diverseeducation.com }
- { dir: diversemilitary.net, stack: leonis, id: 60c28c0dd28860bc334ed723, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-diversemilitary.net }
- { dir: divhealth.net, stack: leonis, id: 60c28c4bd28860bc334f485d, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-divhealth.net }
###############################################
#^# Make sure this matches the site matrix! #^#
###############################################
Expand All @@ -76,9 +76,9 @@ jobs:
###############################################
site:
- { dir: ccnewsnow.com, stack: virgon, id: 60c28bc3d28860bc334ebcb2, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-ccnewsnow.com }
- { dir: diverseeducation.com, stack: virgon, id: 60c281c6d28860bc33464ae0, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-diverseeducation.com }
- { dir: diversemilitary.net, stack: virgon, id: 60c28c0dd28860bc334ed723, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-diversemilitary.net }
- { dir: divhealth.net, stack: virgon, id: 60c28c4bd28860bc334f485d, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-divhealth.net }
- { dir: diverseeducation.com, stack: leonis, id: 60c281c6d28860bc33464ae0, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-diverseeducation.com }
- { dir: diversemilitary.net, stack: leonis, id: 60c28c0dd28860bc334ed723, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-diversemilitary.net }
- { dir: divhealth.net, stack: leonis, id: 60c28c4bd28860bc334f485d, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-divhealth.net }
###############################################
#^# Make sure this matches the site matrix! #^#
###############################################
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/integration-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ jobs:
###############################################
site:
- { dir: ccnewsnow.com, stack: virgon, id: 60c28bc3d28860bc334ebcb2, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-ccnewsnow.com }
- { dir: diverseeducation.com, stack: leonis, id: 60c281c6d28860bc33464ae0, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-diverseeducation.com }
- { dir: diversemilitary.net, stack: leonis, id: 60c28c0dd28860bc334ed723, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-diversemilitary.net }
- { dir: divhealth.net, stack: leonis, id: 60c28c4bd28860bc334f485d, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-divhealth.net }
- { dir: diverseeducation.com, stack: virgon, id: 60c281c6d28860bc33464ae0, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-diverseeducation.com }
- { dir: diversemilitary.net, stack: virgon, id: 60c28c0dd28860bc334ed723, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-diversemilitary.net }
- { dir: divhealth.net, stack: virgon, id: 60c28c4bd28860bc334f485d, account: diverse, tenant: diverse_all, rancher_label: cox-matthews-associates-divhealth.net }
Expand Down
6 changes: 6 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,12 @@ x-env-defaults: &env
ENABLE_CONTENT_METER: ${ENABLE_CONTENT_METER-false}
IDX_NAV_ENABLE: ${IDX_NAV_ENABLE-false}

x-env-leonis: &env-leonis
GRAPHQL_URI: ${GRAPHQL_URI-https://graphql.leonis.base.parameter1.com}
OEMBED_URI: ${OEMBED_URI-https://oembed.leonis.base.parameter1.com}
RSS_URI: ${RSS_URI-https://rss.leonis.base.parameter1.com}
SITEMAPS_URI: ${SITEMAPS_URI-https://sitemaps.leonis.base.parameter1.com}

x-env-virgon: &env-virgon
GRAPHQL_URI: ${GRAPHQL_URI-https://virgon.graphql.base.parameter1.com}
OEMBED_URI: ${OEMBED_URI-https://virgon.oembed.base.parameter1.com}
Expand Down
2 changes: 1 addition & 1 deletion lerna.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "2.22.8",
"version": "2.24.0",
"npmClient": "yarn",
"useWorkspaces": true,
"command": {
Expand Down
26 changes: 8 additions & 18 deletions packages/global/components/document.marko
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import createOmedaIdentityBuilder from "@parameter1/base-cms-marko-web-p1-events/utils/create-omeda-identity-builder";
import { getAsObject } from "@parameter1/base-cms-object-path";
import getCookieId from "@parameter1/base-cms-marko-web-omeda-identity-x/utils/get-cookie-id";

$ const {
site,
Expand All @@ -10,17 +11,6 @@ $ const {
} = out.global;

$ const { cookies } = req;
$ const getCookieId = (value, type) => {
if (!value) return null;
const trimmed = `${value.replace(/^"/, '').replace(/"$/, '')}`.trim();
if (type === 'anon') {
return /^[a-z0-9-]{36}$/i.test(trimmed) ? trimmed : null;
}
if(type === 'enc') {
return /^[a-z0-9]{15}$/i.test(trimmed) ? trimmed : null;
}
return null;
};

$ const omedaConfig = site.get('omeda');

Expand Down Expand Up @@ -79,19 +69,19 @@ $ const omedaConfig = site.get('omeda');

<marko-web-identity-x-context|{ hasUser, user }|>
<if(hasUser && user.id)>
<marko-web-gtm-push data={ user_id: user.id } />
<marko-web-gtm-push data={ user: site.get('identityX').getGTMUserData(user), user_id: user.id} />
</if>
</marko-web-identity-x-context>

<!-- Send Encrypted Omeda Id to GTM -->
$ const oylEncId = cookies.oly_enc_id ? getCookieId(cookies.oly_enc_id, 'enc') : undefined;
<if(oylEncId)>
<marko-web-gtm-push data={ oly_enc_id: oylEncId } />
$ const olyEncId = cookies.oly_enc_id ? getCookieId(cookies.oly_enc_id, 'enc') : undefined;
<if(olyEncId)>
<marko-web-gtm-push data={ oly_enc_id: olyEncId } />
</if>
<!-- Send Anonomouse Omeda Id to GTM -->
$ const oylAnonId = cookies.oly_anon_id ? getCookieId(cookies.oly_anon_id, 'anon') : undefined;
<if(oylAnonId)>
<marko-web-gtm-push data={ oly_anon_id: oylAnonId } />
$ const olyAnonId = cookies.oly_anon_id ? getCookieId(cookies.oly_anon_id, 'anon') : undefined;
<if(olyAnonId)>
<marko-web-gtm-push data={ oly_anon_id: olyAnonId } />
</if>

<!-- start gtm -->
Expand Down
8 changes: 8 additions & 0 deletions packages/global/components/site-header-2.marko
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,14 @@ $ const headerColClass = promos ? `col-lg-${4 - promos.slice(1).length}` : "col-
</theme-site-navbar-brand>
</div>
<div class=`${headerColClass} site-navbar__right`>
<if(site.get('idxNavItems.enable'))>
$ const userLink = (input.hasUser) ? "/user/profile" : "/user/login";
<marko-web-link href=userLink>
<button class="btn btn-lg" type="submit" aria-label="User Profile">
<marko-web-icon name="person" modifiers=["dark"] />
</button>
</marko-web-link>
</if>
<marko-web-link href="/search">
<button class="btn btn-lg" type="submit" aria-label="Search">
<marko-web-icon name="search" modifiers=["dark"] />
Expand Down
4 changes: 2 additions & 2 deletions packages/global/config/native-x.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const NativeXConfiguration = require('@parameter1/base-cms-marko-web-native-x/config');

module.exports = ({
uri = 'https://diverse.native-x.parameter1.com',
uri = 'https://delivery.mindfulcms.com/cma/default/compat/native-website',
enabled = false,
} = {}) => new NativeXConfiguration(uri, { enabled });
} = {}) => new NativeXConfiguration(uri, { enabled, tenantKey: 'diverse' });
28 changes: 14 additions & 14 deletions packages/global/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cox-matthews-associates/package-global",
"version": "2.22.8",
"version": "2.23.1",
"author": "Brian Miller <[email protected]>",
"repository": "https://github.com/parameter1/ab-media-websites/tree/master/packages/global",
"license": "MIT",
Expand All @@ -16,28 +16,28 @@
"@parameter1/base-cms-dayjs": "^4.5.12",
"@parameter1/base-cms-image": "^4.6.0",
"@parameter1/base-cms-inflector": "^4.5.12",
"@parameter1/base-cms-marko-core": "^4.32.0",
"@parameter1/base-cms-marko-web": "^4.32.0",
"@parameter1/base-cms-marko-core": "^4.36.0",
"@parameter1/base-cms-marko-web": "^4.38.1",
"@parameter1/base-cms-marko-web-contact-us": "^4.5.12",
"@parameter1/base-cms-marko-web-deferred-script-loader": "^4.5.12",
"@parameter1/base-cms-marko-web-gam": "^4.5.12",
"@parameter1/base-cms-marko-web-gcse": "^4.5.12",
"@parameter1/base-cms-marko-web-gtm": "^4.17.1",
"@parameter1/base-cms-marko-web-gtm": "^4.38.1",
"@parameter1/base-cms-marko-web-html-sitemap": "^4.5.12",
"@parameter1/base-cms-marko-web-icons": "^4.27.0",
"@parameter1/base-cms-marko-web-identity-x": "^4.29.0",
"@parameter1/base-cms-marko-web-native-x": "^4.32.0",
"@parameter1/base-cms-marko-web-icons": "^4.36.8",
"@parameter1/base-cms-marko-web-identity-x": "^4.38.2",
"@parameter1/base-cms-marko-web-native-x": "^4.38.1",
"@parameter1/base-cms-marko-web-omeda": "^4.23.1",
"@parameter1/base-cms-marko-web-omeda-identity-x": "^4.29.0",
"@parameter1/base-cms-marko-web-p1-events": "^4.33.1",
"@parameter1/base-cms-marko-web-search": "^4.32.0",
"@parameter1/base-cms-marko-web-social-sharing": "^4.32.0",
"@parameter1/base-cms-marko-web-theme-monorail": "^4.33.2",
"@parameter1/base-cms-marko-web-theme-monorail-magazine": "^4.32.0",
"@parameter1/base-cms-marko-web-omeda-identity-x": "^4.38.2",
"@parameter1/base-cms-marko-web-p1-events": "^4.38.0",
"@parameter1/base-cms-marko-web-search": "^4.36.8",
"@parameter1/base-cms-marko-web-social-sharing": "^4.36.8",
"@parameter1/base-cms-marko-web-theme-monorail": "^4.38.2",
"@parameter1/base-cms-marko-web-theme-monorail-magazine": "^4.38.2",
"@parameter1/base-cms-object-path": "^4.5.12",
"@parameter1/base-cms-utils": "^4.5.12",
"@parameter1/base-cms-web-cli": "^4.18.3",
"@parameter1/base-cms-web-common": "^4.32.0",
"@parameter1/base-cms-web-common": "^4.36.0",
"@parameter1/omeda-graphql-client-express": "^0.2.3",
"graphql": "^14.5.4",
"graphql-tag": "^2.10.1",
Expand Down
5 changes: 5 additions & 0 deletions packages/global/scss/core.scss
Original file line number Diff line number Diff line change
Expand Up @@ -291,6 +291,11 @@
}
}

a {
&:hover {
text-decoration: none;
}
}

// skin components
/*! critical:start|website-section.on-the-move */
Expand Down
4 changes: 4 additions & 0 deletions packages/global/templates/content/native-x-story.marko
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,11 @@ $ const { primarySection } = content;

<theme-default-page title=story.title description=story.teaser>
<@head>
<marko-web-gtm-native-x-story-context|{ context }| obj=content>
<marko-web-gtm-push data=context />
</marko-web-gtm-native-x-story-context>
<marko-web-native-x-gtm-init />
<marko-web-p1-events-track-native-story story=story />
</@head>
<@page>
<marko-web-native-x-story-track-init story=story />
Expand Down
29 changes: 17 additions & 12 deletions sites/ccnewsnow.com/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cox-matthews-associates/ccnewsnow.com",
"version": "2.22.8",
"version": "2.24.0",
"author": "Brandon Krigbaum <[email protected]>",
"repository": "https://github.com/parameter1/cox-matthews-associates-websites/tree/master/sites/ccnewsnow.com",
"license": "MIT",
Expand All @@ -11,7 +11,12 @@
"account": "diverse",
"stack": "virgon",
"key": "ccn",
"deploy": true
"deploy": {
"production": true,
"staging": {
"stack": "leonis"
}
}
},
"scripts": {
"dev": "basecms-website dev --compile-dir ../../packages --watch-dir ../../packages --purge-css-content-dir ../../packages --purge-css-content-dir ../../node_modules/@parameter1",
Expand All @@ -31,19 +36,19 @@
"win32"
],
"dependencies": {
"@cox-matthews-associates/package-global": "^2.22.8",
"@parameter1/base-cms-marko-core": "^4.32.0",
"@parameter1/base-cms-marko-web": "^4.32.0",
"@cox-matthews-associates/package-global": "^2.23.1",
"@parameter1/base-cms-marko-core": "^4.36.0",
"@parameter1/base-cms-marko-web": "^4.38.1",
"@parameter1/base-cms-marko-web-gam": "^4.5.12",
"@parameter1/base-cms-marko-web-gcse": "^4.5.12",
"@parameter1/base-cms-marko-web-gtm": "^4.17.1",
"@parameter1/base-cms-marko-web-icons": "^4.27.0",
"@parameter1/base-cms-marko-web-leaders": "^4.27.0",
"@parameter1/base-cms-marko-web-native-x": "^4.32.0",
"@parameter1/base-cms-marko-web-p1-events": "^4.33.1",
"@parameter1/base-cms-marko-web-gtm": "^4.38.1",
"@parameter1/base-cms-marko-web-icons": "^4.36.8",
"@parameter1/base-cms-marko-web-leaders": "^4.36.8",
"@parameter1/base-cms-marko-web-native-x": "^4.38.1",
"@parameter1/base-cms-marko-web-p1-events": "^4.38.0",
"@parameter1/base-cms-marko-web-reveal-ad": "^4.5.12",
"@parameter1/base-cms-marko-web-theme-monorail": "^4.33.2",
"@parameter1/base-cms-marko-web-theme-monorail-magazine": "^4.32.0",
"@parameter1/base-cms-marko-web-theme-monorail": "^4.38.2",
"@parameter1/base-cms-marko-web-theme-monorail-magazine": "^4.38.2",
"@parameter1/base-cms-object-path": "^4.5.12",
"@parameter1/base-cms-utils": "^4.5.12",
"@parameter1/base-cms-web-cli": "^4.18.3",
Expand Down
4 changes: 0 additions & 4 deletions sites/ccnewsnow.com/server/templates/index.marko
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,6 @@ $ const { id, alias, name, pageNode } = input;
/>
</@section>

<@section>
<theme-native-x-promo-card-block placement-name="promotion" />
</@section>

<@section>
<div role="region" aria-label="Most Popular Stories">
<theme-client-side-most-popular-block />
Expand Down
3 changes: 3 additions & 0 deletions sites/diverseeducation.com/config/identity-x.js
Original file line number Diff line number Diff line change
Expand Up @@ -121,4 +121,7 @@ module.exports = configureIdentityX({
forms: {
default: formDefault,
},
gtmUserFields: {
categories: '64c03173d786a63621af8423',
},
});
29 changes: 17 additions & 12 deletions sites/diverseeducation.com/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cox-matthews-associates/diverseeducation.com",
"version": "2.22.8",
"version": "2.24.0",
"author": "Brandon Krigbaum <[email protected]>",
"repository": "https://github.com/parameter1/cox-matthews-associates-websites/tree/master/sites/diverseeducation.com",
"license": "MIT",
Expand All @@ -11,7 +11,12 @@
"account": "diverse",
"stack": "virgon",
"key": "de",
"deploy": true
"deploy": {
"production": true,
"staging": {
"stack": "leonis"
}
}
},
"scripts": {
"dev": "basecms-website dev --compile-dir ../../packages --watch-dir ../../packages --purge-css-content-dir ../../packages --purge-css-content-dir ../../node_modules/@parameter1",
Expand All @@ -31,19 +36,19 @@
"win32"
],
"dependencies": {
"@cox-matthews-associates/package-global": "^2.22.8",
"@parameter1/base-cms-marko-core": "^4.32.0",
"@parameter1/base-cms-marko-web": "^4.32.0",
"@cox-matthews-associates/package-global": "^2.23.1",
"@parameter1/base-cms-marko-core": "^4.36.0",
"@parameter1/base-cms-marko-web": "^4.38.1",
"@parameter1/base-cms-marko-web-gam": "^4.5.12",
"@parameter1/base-cms-marko-web-gcse": "^4.5.12",
"@parameter1/base-cms-marko-web-gtm": "^4.17.1",
"@parameter1/base-cms-marko-web-icons": "^4.27.0",
"@parameter1/base-cms-marko-web-leaders": "^4.27.0",
"@parameter1/base-cms-marko-web-native-x": "^4.32.0",
"@parameter1/base-cms-marko-web-p1-events": "^4.33.1",
"@parameter1/base-cms-marko-web-gtm": "^4.38.1",
"@parameter1/base-cms-marko-web-icons": "^4.36.8",
"@parameter1/base-cms-marko-web-leaders": "^4.36.8",
"@parameter1/base-cms-marko-web-native-x": "^4.38.1",
"@parameter1/base-cms-marko-web-p1-events": "^4.38.0",
"@parameter1/base-cms-marko-web-reveal-ad": "^4.5.12",
"@parameter1/base-cms-marko-web-theme-monorail": "^4.33.2",
"@parameter1/base-cms-marko-web-theme-monorail-magazine": "^4.32.0",
"@parameter1/base-cms-marko-web-theme-monorail": "^4.38.2",
"@parameter1/base-cms-marko-web-theme-monorail-magazine": "^4.38.2",
"@parameter1/base-cms-object-path": "^4.5.12",
"@parameter1/base-cms-utils": "^4.5.12",
"@parameter1/base-cms-web-cli": "^4.18.3",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,8 @@
"type" : "string",
"required": true
}
},
"<site-promo-card-rotation-block>": {
"template": "./promo-card-rotation.marko"
}
}
Loading

0 comments on commit d6a67ac

Please sign in to comment.