Skip to content

Commit

Permalink
MWPW-158464: Switch Odin endpoint (#2894)
Browse files Browse the repository at this point in the history
* init plans cards doc

* switch to QA bucket

* add plans html

* add test payload

* upd path

* card

* test hlxignore

* test

* remove test files

* remove edge payload

* add marquee

* add spacing
  • Loading branch information
3ch023 authored Sep 19, 2024
1 parent e3844f2 commit c80cf18
Show file tree
Hide file tree
Showing 9 changed files with 620 additions and 370 deletions.
1 change: 1 addition & 0 deletions .hlxignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ LICENSE
web-test-runner.config.mjs
codecov.yaml
libs/features/mas/*
!libs/features/mas/docs
8 changes: 4 additions & 4 deletions libs/deps/mas/mas.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion libs/deps/mas/merch-datasource.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

64 changes: 64 additions & 0 deletions libs/features/mas/docs/plans.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@

<!DOCTYPE html>
<html>
<head>
<title>Plans merch cards</title>
<meta name="access-control-allow-origin" content="*">
<meta name="robots" content="noindex, nofollow">
<meta name="nofollow-links" content="on">
<meta name="viewport" content="width=device-width, initial-scale=1">
<script src="/libs/scripts/scripts.js" type="module"></script>
<script src="/libs/deps/mas/mas.js" type="module"></script>
<link rel="stylesheet" href="/libs/styles/styles.css">
</head>
<body>
<header></header>
<main>
<div class="section dark xs-spacing" style="background: rgb(34, 34, 34);" daa-lh="s1">
<div class="text text-block con-block" daa-lh="b1|text">
<div class="foreground">
<div>M@S2 Components</div>
</div>
</div>
<div class="columns contained static-links columns-table" daa-lh="b2|columns">
<div class="row row-1">
<div data-valign="middle" class="col col-1"><strong class="tracking-header">Explore</strong></div>
<div data-valign="middle" class="col col-2"></div>
</div>
<div class="row row-2">
<div data-valign="middle" class="col col-1">
<ul>
<li><a href="/libs/features/mas/docs/plans.html">Plans Cards</a></li>
</ul>
</div>
<div data-valign="middle" class="col col-2">
<p>Merch @ Scale (M@S), is a system developed by the Adobe.com Warriors engineering team designed to streamline the authoring, configuration, and display of pricing data on adobe.com.</p>
<p>Contact us in Slack: #tacocat-friends</p>
</div>
</div>
</div>
<div class="section-metadata">
<div>
<div>style</div>
<div>Dark, xs spacing</div>
</div>
<div>
<div>background</div>
<div>#222222</div>
</div>
</div>
<div class="text center xl-spacing-bottom xl-spacing-top text-block con-block" daa-lh="b3|text">
<div class="foreground">
<div data-valign="middle">
<h2 id="merch-cards" class="heading-l">&lt;&lt;Merch cards&gt;&gt;</h2>
</div>
</div>
</div>
</div>
<div class="section m-spacing">
<merch-card><merch-datasource path="/content/dam/mas/acom/us/en/creative-cloud-all-apps"></merch-datasource></merch-card>
</div>
</main>
<footer></footer>
</body>
</html>
4 changes: 2 additions & 2 deletions libs/features/mas/mocks/aem.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@ export async function withAem(originalFetch) {
if (/cf\/fragments\/search/.test(pathname)) {
// TODO add conditional use case.
return originalFetch(
'/test/mocks/sites/cf/fragments/search/default.json',
'/test/mocks/sites/cf/fragments/search/authorPayload.json',
);
} else if (/cf\/fragments/.test(pathname) && searchParams.has('path')) {
const path = searchParams.get('path');
const item = await originalFetch(
'/test/mocks/sites/cf/fragments/search/default.json',
'/test/mocks/sites/cf/fragments/search/authorPayload.json',
)
.then((res) => res.json())
.then(({ items }) => items.find((item) => item.path === path));
Expand Down
Loading

0 comments on commit c80cf18

Please sign in to comment.