Skip to content

Commit

Permalink
Merge branch 'master' into remove-css-classes
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-beck authored Aug 17, 2023
2 parents 594d145 + 97ac833 commit dcd007b
Show file tree
Hide file tree
Showing 24 changed files with 354 additions and 380 deletions.
2 changes: 1 addition & 1 deletion ath.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ set -o xtrace
cd "$(dirname "$0")"

# https://github.com/jenkinsci/acceptance-test-harness/releases
export ATH_VERSION=5691.v64cd2e005b_8b_
export ATH_VERSION=5699.v27deb_ef5796c

if [[ $# -eq 0 ]]; then
export JDK=17
Expand Down
4 changes: 1 addition & 3 deletions core/src/main/resources/hudson/PluginManager/_installed.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,7 @@
function updateMsg() {
// has anything changed since its original state?
let e = Array.from(
document
.getElementById("plugins")
.querySelectorAll("input[type='checkbox']"),
document.querySelectorAll("#plugins input[type='checkbox']"),
).find(function (e) {
return String(e.checked) !== e.getAttribute("original");
});
Expand Down
47 changes: 21 additions & 26 deletions core/src/main/resources/hudson/PluginManager/installed.jelly
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,17 @@ THE SOFTWARE.
<l:main-panel>
<l:app-bar title="${%Plugins}" />

<j:set var="noPlugins"
value="${empty(app.pluginManager.plugins) and empty(app.pluginManager.failedPlugins)}" />

<div class="jenkins-app-bar jenkins-app-bar--sticky">
<div class="jenkins-app-bar__content">
<l:search-bar clazz="jenkins-search--app-bar"
placeholder="${%Search installed plugins}"
id="filter-box"
autofocus="true"
value="${request.getParameter('filter')}" />
value="${request.getParameter('filter')}"
enabled="${!noPlugins}" />
</div>
</div>

Expand All @@ -67,29 +71,20 @@ THE SOFTWARE.
data-detached-possible-dependents="${%detached-possible-dependents}"
data-uninstall-description="${%uninstall-description}" />

<table id="plugins" class="jenkins-table sortable">
<j:choose>
<j:when test="${empty(app.pluginManager.plugins) and empty(app.pluginManager.failedPlugins)}">
<thead>
<tr>
<th>${%Installed plugins}</th>
</tr>
</thead>
<tbody>
<tr>
<td align="center">${%No plugins installed.}</td>
</tr>
</tbody>
</j:when>
<j:otherwise>
<j:choose>
<j:when test="${noPlugins}">
<l:notice icon="symbol-plugins" text="${%No plugins installed}" />
</j:when>
<j:otherwise>
<table id="plugins" class="jenkins-table sortable">
<thead>
<tr>
<th initialSortDir="down">${%Name}</th>
<th class="jenkins-table__cell--tight">${%Enabled}</th>
<l:isAdmin>
<th data-sort-disable="true"/>
</l:isAdmin>
</tr>
<tr>
<th initialSortDir="down">${%Name}</th>
<th class="jenkins-table__cell--tight">${%Enabled}</th>
<l:isAdmin>
<th data-sort-disable="true"/>
</l:isAdmin>
</tr>
</thead>
<tbody>
<j:forEach var="p" items="${app.pluginManager.plugins}">
Expand Down Expand Up @@ -274,9 +269,9 @@ THE SOFTWARE.
</tr>
</j:forEach>
</tbody>
</j:otherwise>
</j:choose>
</table>
</table>
</j:otherwise>
</j:choose>

<div class="warning" id="needRestart" style="display:none; margin: 1em; height: 1em">
<form method="post" action="${rootURL}/safeRestart">
Expand Down
341 changes: 168 additions & 173 deletions core/src/main/resources/hudson/PluginManager/updates.jelly

Large diffs are not rendered by default.

22 changes: 6 additions & 16 deletions core/src/main/resources/hudson/model/AllView/noJob.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,7 @@ div {
a(href: "newJob", class: "content-block__link") {
span(_("createJob"))
span(class: "trailing-icon") {
l.icon(
class: "icon-md",
src: "symbol-arrow-right")
l.icon(src: "symbol-add")
}
}
}
Expand All @@ -48,9 +46,7 @@ div {
a(href: "computer/new", class: "content-block__link") {
span(_("setUpAgent"))
span(class: "trailing-icon") {
l.icon(
class: "icon-md",
src: "symbol-arrow-right")
l.icon(src: "symbol-computer")
}
}
}
Expand All @@ -60,9 +56,7 @@ div {
a(href: "cloud/", class: "content-block__link") {
span(_("setUpCloud"))
span(class: "trailing-icon") {
l.icon(
class: "icon-md",
src: "symbol-arrow-right")
l.icon(src: "symbol-cloud")
}
}
}
Expand All @@ -71,12 +65,10 @@ div {
li(class: "content-block") {
a(href: "https://www.jenkins.io/redirect/distributed-builds",
target: "_blank",
class: "content-block__link content-block__help-link") {
class: "content-block__link") {
span(_("learnMoreDistributedBuilds"))
span(class: "trailing-icon") {
l.icon(
class: "icon-md",
src: "symbol-link")
l.icon(src: "symbol-help-circle")
}
}
}
Expand All @@ -96,9 +88,7 @@ div {
a(href: "newJob", class: "content-block__link") {
span(_("createJob"))
span(class: "trailing-icon") {
l.icon(
class: "icon-md",
src: "symbol-arrow-right")
l.icon(src: "symbol-add")
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/resources/hudson/model/View/main.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@ if (items == null) {
include(my.owner.viewsTabBar,"viewTabs")
}
}
}
}
8 changes: 4 additions & 4 deletions core/src/main/resources/jenkins/agents/CloudSet/index.jelly
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ THE SOFTWARE.
class="content-block__link">
<span>${%newCloud}</span>
<span class="trailing-icon">
<l:icon class="icon-md" src="symbol-arrow-right"/>
<l:icon src="symbol-add"/>
</span>
</a>
</li>
Expand All @@ -100,17 +100,17 @@ THE SOFTWARE.
class="content-block__link">
<span>${%installCloudPlugin}</span>
<span class="trailing-icon">
<l:icon class="icon-md" src="symbol-arrow-right"/>
<l:icon src="symbol-plugins" />
</span>
</a>
</li>
<li class="content-block">
<a href="https://www.jenkins.io/redirect/distributed-builds"
class="content-block__link content-block__help-link"
class="content-block__link"
target="_blank" rel="noopener noreferrer">
<span>${%learnMoreDistributedBuilds}</span>
<span class="trailing-icon">
<l:icon class="icon-md" src="symbol-link"/>
<l:icon src="symbol-help-circle" />
</span>
</a>
</li>
Expand Down
37 changes: 17 additions & 20 deletions core/src/main/resources/jenkins/model/Jenkins/systemInfo.jelly
Original file line number Diff line number Diff line change
Expand Up @@ -50,24 +50,21 @@ THE SOFTWARE.
</l:hasPermission>

<l:tabPane title="${%Plugins}">
<table class="jenkins-table sortable">
<thead>
<tr>
<th initialSortDir="down">${%Name}</th>
<th>${%Version}</th>
<th>${%Enabled}</th>
</tr>
</thead>
<tbody>
<j:choose>
<j:when test="${empty(app.pluginManager.plugins) and empty(app.pluginManager.failedPlugins)}">

<j:choose>
<j:when test="${empty(app.pluginManager.plugins) and empty(app.pluginManager.failedPlugins)}">
<l:notice icon="symbol-plugins" text="${%No plugins installed}" />
</j:when>
<j:otherwise>
<table class="jenkins-table sortable">
<thead>
<tr>
<td colspan="3">
${%No plugins installed.}
</td>
<th initialSortDir="down">${%Name}</th>
<th>${%Version}</th>
<th>${%Enabled}</th>
</tr>
</j:when>
<j:otherwise>
</thead>
<tbody>
<j:forEach var="p" items="${app.pluginManager.plugins}">
<j:set var="state" value="${p.enabled?'true':'false'}"/>
<tr>
Expand All @@ -84,10 +81,10 @@ THE SOFTWARE.
</td>
</tr>
</j:forEach>
</j:otherwise>
</j:choose>
</tbody>
</table>
</tbody>
</table>
</j:otherwise>
</j:choose>
</l:tabPane>

<l:tabPane title="${%Memory Usage}">
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/resources/lib/form/apply/apply.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Behaviour.specify(
}

e.addEventListener("click", function (e) {
var f = findAncestor(e.target, "FORM");
var f = e.target.closest("FORM");

// create a throw-away IFRAME to avoid back button from loading the POST result back
id = "iframe" + iota++;
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/resources/lib/form/radioBlock/radioBlock.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ Behaviour.specify(
g.buttons = [];
}

var s = findAncestorClass(r, "radio-block-start");
var s = r.closest(".radio-block-start");
s.setAttribute("ref", r.id);

// find the end node
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/resources/lib/form/repeatable/repeatable.js
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ var repeatableSupport = {

// called when 'delete' button is clicked
onDelete: function (n) {
n = findAncestorClass(n, "repeated-chunk");
n = n.closest(".repeated-chunk");
var a = new YAHOO.util.Anim(
n,
{
Expand Down
8 changes: 6 additions & 2 deletions core/src/main/resources/lib/layout/search-bar.jelly
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,16 @@ THE SOFTWARE.
<st:attribute name="hasKeyboardShortcut">
If false the default keyboard shortcut for the input is disabled. Defaults to true.
</st:attribute>
<st:attribute name="enabled" since="TODO">
Defaults to true. Sets whether the search bar is enabled or not.
</st:attribute>
Creates a search input

@since 2.369
</st:documentation>

<div class="jenkins-search-container">
<div class="jenkins-search ${attrs.clazz}">
<div class="jenkins-search ${attrs.enabled == false ? 'jenkins-search--disabled' : ''} ${attrs.clazz}">
<div class="jenkins-search__icon">
<l:icon src="symbol-search" />
</div>
Expand All @@ -52,7 +55,8 @@ THE SOFTWARE.
autocomplete="off"
autocorrect="off"
autocapitalize="off"
spellcheck="false" />
spellcheck="false"
disabled="${attrs.enabled == false ? true : null}" />
<j:if test="${attrs.hasKeyboardShortcut != 'false'}">
<div class="jenkins-search__shortcut" tooltip="${%Press / on your keyboard to focus}">
<l:icon src="symbol-search-shortcut" />
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ THE SOFTWARE.
</issueManagement>

<properties>
<revision>2.419</revision>
<revision>2.420</revision>
<changelist>-SNAPSHOT</changelist>

<!-- configuration for patch tracker plugin -->
Expand Down
6 changes: 3 additions & 3 deletions test/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ THE SOFTWARE.
<!-- requireUpperBoundDeps via matrix-project and junit -->
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>script-security</artifactId>
<version>1264.vecf66020eb_7d</version>
<version>1269.v639888f5e366</version>
</dependency>
</dependencies>
</dependencyManagement>
Expand Down Expand Up @@ -185,7 +185,7 @@ THE SOFTWARE.
<dependency>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>cloudbees-folder</artifactId>
<version>6.846.v23698686f0f6</version>
<version>6.848.ve3b_fd7839a_81</version>
<scope>test</scope>
</dependency>
<dependency>
Expand Down Expand Up @@ -215,7 +215,7 @@ THE SOFTWARE.
<dependency>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>matrix-project</artifactId>
<version>802.v8013b_40c7edc</version>
<version>808.v5a_b_5f56d6966</version>
<scope>test</scope>
</dependency>
<dependency>
Expand Down
2 changes: 1 addition & 1 deletion war/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
"clean-webpack-plugin": "4.0.0",
"css-loader": "6.8.1",
"css-minimizer-webpack-plugin": "5.0.1",
"eslint": "8.46.0",
"eslint": "8.47.0",
"eslint-config-prettier": "9.0.0",
"handlebars-loader": "1.7.3",
"mini-css-extract-plugin": "2.7.6",
Expand Down
1 change: 1 addition & 0 deletions war/src/main/resources/images/symbols/up-to-date.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 14 additions & 0 deletions war/src/main/scss/abstracts/mixins.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
@mixin link {
text-decoration: var(--link-text-decoration);
font-weight: var(--link-font-weight);
text-underline-offset: 2px;
text-decoration-thickness: 2px;

&:link {
color: var(--link-color);
Expand All @@ -20,6 +22,14 @@
color: var(--link-color--active);
text-decoration: var(--link-text-decoration--active);
}

@media (prefers-contrast: more) {
text-decoration: underline;

&:hover {
text-decoration-thickness: 3px;
}
}
}

@mixin link-dark {
Expand Down Expand Up @@ -70,6 +80,10 @@
box-shadow: 0 0 0 0.66rem transparent;
}

&:focus-visible {
outline: none;
}

&:not(:disabled) {
&:hover,
&:focus-visible {
Expand Down
2 changes: 1 addition & 1 deletion war/src/main/scss/abstracts/theme.scss
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ $semantics: (
--link-text-decoration: none;
--link-text-decoration--hover: underline;
--link-text-decoration--active: underline;
--link-font-weight: 600;
--link-font-weight: 500;

// Tooltips
--tooltip-backdrop-filter: contrast(0.6) brightness(2.4) saturate(2)
Expand Down
Loading

0 comments on commit dcd007b

Please sign in to comment.