Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge main into branch #13400

Merged
merged 33 commits into from
Dec 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
79142ad
Pass along UTMs when doing a blog redirect
caldav Nov 29, 2023
8f4c3ad
WD-7769 - fix typo in gcp fips
Dec 4, 2023
c590280
Move query_string fetching deeper in the logic
caldav Dec 5, 2023
d224a82
Merge pull request #13387 from lizzochek/task/WD-7769
lizzochek Dec 5, 2023
da29a1a
WD-7771 - update buttons in /robotics
Dec 5, 2023
40f55f2
WD-7815 - redirect from embedded to real-time
Dec 5, 2023
40bd38e
Update templates/robotics/index.html
lizzochek Dec 5, 2023
1304573
Update templates/robotics/index.html
lizzochek Dec 5, 2023
b5b0c2a
Update templates/robotics/index.html
lizzochek Dec 5, 2023
aa28d66
Update templates/robotics/index.html
lizzochek Dec 5, 2023
cd6b591
Update templates/robotics/index.html
lizzochek Dec 5, 2023
f708a6f
Update templates/robotics/index.html
lizzochek Dec 5, 2023
b72e240
Merge pull request #13390 from lizzochek/task/WD-7771
lizzochek Dec 5, 2023
143e5ea
Merge pull request #13381 from caldav/blog-redirects-with-utms
akbarkz Dec 6, 2023
d415c29
Merge pull request #13391 from lizzochek/task/WD-7815
lizzochek Dec 6, 2023
c563c99
add landing page for Chiselled Ubuntu without the chart and a table
akbarkz Dec 1, 2023
9033397
fix links, form ID and text in /containers/chiselled page
akbarkz Dec 1, 2023
8eafafe
visual review
lyubomir-popov Dec 1, 2023
f729226
fix chisel word's case in different places
akbarkz Dec 4, 2023
a0edbe3
add table and a chart to /containers/chiselled page
akbarkz Dec 8, 2023
76bd480
add accessibility tags to a table
akbarkz Dec 8, 2023
89836a3
rename variable, add alt text to an image, fix formatting
akbarkz Dec 8, 2023
a58e012
do not write the word 'Java' with all capital letters
akbarkz Dec 8, 2023
ed8f73d
replace main image on /containers/chiselled page
akbarkz Dec 8, 2023
935fdd3
Update links
albertkol Dec 8, 2023
1a419ab
Merge pull request #13393 from albertkol/update-links
albertkol Dec 11, 2023
1c90b5c
Merge pull request #13394 from akbarkz/task/WD-7724-chiselled_chart
akbarkz Dec 11, 2023
9c44899
Merge pull request #13389 from canonical/chiselled-ubuntu
akbarkz Dec 12, 2023
4d42e98
update image on /confidential-computing page
akbarkz Dec 12, 2023
e695e2c
Update internal dependencies
renovate[bot] Dec 12, 2023
7defa3a
Merge pull request #13397 from akbarkz/task/WD-7905-replace_image
akbarkz Dec 12, 2023
029747b
Remove breaking dependencies
carkod Dec 12, 2023
4310191
Merge pull request #12854 from canonical/renovate/internal
carkod Dec 12, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion build.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@ let entries = {
"kernel-form": "./static/js/src/kernel-form.js",
"random-partner-logos": "./static/js/src/random-partner-logos.js",
"credEnterprisePurchasing": "./static/js/src/advantage/credentials/app.tsx",
activate: "./static/js/src/activate.js"
activate: "./static/js/src/activate.js",
"chiselled-chart": "./static/js/src/charts/chiselled-chart.js"
};

const isDev = process && process.env && process.env.NODE_ENV === "development";
Expand Down
2 changes: 2 additions & 0 deletions navigation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,8 @@ containers:
- title: What are containers
path: /containers/what-are-containers
- title: Chiselled Ubuntu
path: /containers/chiselled
- title: Chiselled and .NET
path: /containers/chiselled/dotnet

ai:
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@
"typescript": "4.5.4",
"url-polyfill": "1.1.12",
"url-search-params-polyfill": "8.1.1",
"vanilla-framework": "4.3.0",
"vanilla-framework": "4.5.1",
"yup": "0.32.11"
},
"resolutions": {
Expand Down
1 change: 1 addition & 0 deletions redirects.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -463,6 +463,7 @@ ec2/?: "/cloud/public-cloud"
edge/?: "/edge-computing"
edge-cloud/?: "/cloud"
education.*/?: "/desktop/education"
embedded: "/real-time"
employment/?: "https://www.canonical.com/careers"
employment/SSEBzr/?: "https://www.canonical.com/careers"
end-of-life/?: "/about/release-cycle"
Expand Down
6 changes: 3 additions & 3 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
canonicalwebteam.flask-base==1.1.0
canonicalwebteam.http==1.0.3
canonicalwebteam.blog==6.4.1
canonicalwebteam.http==1.0.4
canonicalwebteam.blog==6.4.2
canonicalwebteam.search==1.3.0
canonicalwebteam.templatefinder==1.0.0
canonicalwebteam.image-template==1.3.1
canonicalwebteam.discourse==5.4.5
canonicalwebteam.discourse==5.4.7
python-dateutil==2.8.2
pytz==2022.7.1
maxminddb-geolite2==2018.703
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
import { ICONS, Icon, List, Tabs, Tooltip } from "@canonical/react-components";
import React, { HTMLProps, useState } from "react";
import type { ReactNode } from "react";
import React, { HTMLProps, useState } from "react";
import { Icon, ICONS, List, Tabs, Tooltip } from "@canonical/react-components";
import { UserSubscription } from "advantage/api/types";
import {
EntitlementsStore,
filterAndFormatEntitlements,
} from "advantage/react/utils/filterAndFormatEntitlements";
import {
isBlenderSubscription,
isFreeSubscription,
} from "advantage/react/utils";
import {
EntitlementsStore,
filterAndFormatEntitlements,
} from "advantage/react/utils/filterAndFormatEntitlements";
import { sendAnalyticsEvent } from "advantage/react/utils/sendAnalyticsEvent";
import FeaturesTab from "./components/FeaturesTab";

Expand Down Expand Up @@ -113,7 +113,7 @@ const DetailsTabs = ({
<tr>
<td data-test="doc-link">Knowledge Base</td>
<td>
<a href="https://portal.support.canonical.com/?_ga=2.3371065.849364026.1691488233-1001052631.1648559628">
<a href="https://support-portal.canonical.com/knowledge-base">
Online library of articles and tutorials
</a>
</td>
Expand All @@ -122,7 +122,7 @@ const DetailsTabs = ({
<tr>
<td data-test="doc-link">{supportLevel}</td>
<td>
<a href="https://portal.support.canonical.com/staff/s/contactsupport">
<a href="https://support-portal.canonical.com/contact-us">
Phone and ticket support
</a>
</td>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ export const SubscriptionDetails = forwardRef<HTMLDivElement, Props>(
data-test="support-button"
disabled={editing}
element="a"
href="https://portal.support.canonical.com/"
href="https://support-portal.canonical.com/"
>
Support portal
</Button>
Expand Down
94 changes: 94 additions & 0 deletions static/js/src/charts/chiselled-chart.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
import { debounce } from "../utils/debounce.js";

function buildChiselledChart(selector, data, isFirst) {
const colors = ["#CBA7B8", "#923A66", "#000000"];

const width = document.querySelector(selector).getBoundingClientRect().width;

const x = d3.scaleLinear().range([0, width]).domain([0, 330]);

const withAxis = screen.width < 1036 || isFirst;

const svg = d3
.select(selector)
.append("svg")
.attr("width", width)
.attr("height", `${2.5 * (data.length + (withAxis ? 1 : 0))}em`); // make the height bigger if it shows with axis

const xAxis = d3.axisTop(x).ticks(3).tickSizeInner(24).tickSizeOuter(0);

const axisG = svg.append("g");

if (withAxis) axisG.style("transform", "translate(0, 2.3rem)");

axisG.call(xAxis);

axisG
.selectAll("text")
.attr("transform", "translate(5, 20)")
.attr("text-anchor", "start")
.style("font-size", "1.6em")
.style("color", "#666666");

axisG
.select(".domain")
.attr("transform", "translate(0, -2)")
.attr("stroke", "#000000")
.attr("stroke-width", "1px")
.attr("opacity", "0.2");

axisG
.selectAll("line")
.attr("transform", "translate(0, -2)")
.attr("stroke", "#000000")
.attr("stroke-width", "1px")
.attr("opacity", "0.2");

const chartG = svg.append("g");

if (withAxis) chartG.style("transform", "translate(0, 2.4em)");

chartG
.selectAll()
.data(data)
.enter()
.append("rect")
.attr("fill", function (d, i) {
if (i === data.length - 1) return colors[colors.length - 1];
return colors[i];
})
.attr("x", 0)
.attr("y", function (d, i) {
return `${2.5 * i}em`;
})
.attr("height", "2.35em")
.attr("width", function (d, i) {
return x(d);
})
.attr("aria-label", function (d, i) {
return `${d} MB`;
});
}

function clearChiselledChart(selector) {
const chart = document.querySelector(selector);
if (chart) {
chart.innerHTML = "";
}
}

window.addEventListener(
"resize",
debounce(function () {
clearChiselledChart("#chiselled-dotnet-chart");
clearChiselledChart("#chiselled-java-chart");
clearChiselledChart("#chiselled-other-chart");
buildChiselledChart("#chiselled-dotnet-chart", [219, 116, 5], true);
buildChiselledChart("#chiselled-java-chart", [215, 113]);
buildChiselledChart("#chiselled-other-chart", [20, 12]);
}, 250)
);

buildChiselledChart("#chiselled-dotnet-chart", [219, 116, 5], true);
buildChiselledChart("#chiselled-java-chart", [215, 113]);
buildChiselledChart("#chiselled-other-chart", [20, 12]);
2 changes: 1 addition & 1 deletion templates/confidential-computing/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ <h2>Intel TDX is available on Ubuntu for both the host and guest</h2>
</p>
<div class="u-align--center u-vertically-center u-hide--small">
{{ image (
url="https://assets.ubuntu.com/v1/4143661e-Ubuntu%20VM%20on%20Intel%20TDX.png",
url="https://assets.ubuntu.com/v1/48765e85-Intel%20%20TDX%20and%20Ubuntu%20Figure.png",
alt="Diagram showing that Ubuntu builds cater to both the host and guest sides, empowering users to launch a
confidential TDX virtual machine seamlessly",
width="410",
Expand Down
2 changes: 1 addition & 1 deletion templates/containers/chiselled/_base_chiselled.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{% extends "templates/base.html" %}

{% block meta_copydoc %}https://drive.google.com/drive/folders/1KzbPY6u1J4_F4-sVTR8fGnbD16EpIpAW{% endblock meta_copydoc %}
{% block meta_copydoc %}https://docs.google.com/document/d/1ZkQ-UFTwsPkMnQn8IEEjZOXMy40tkgBscw_-qq9K3nc/edit{% endblock meta_copydoc %}

{% block outer_content %}
{% block content %}{% endblock %}
Expand Down
Loading
Loading