Skip to content

Commit 1aad214

Browse files
committed
[MPLUGIN-514] switch from png+imagemap to svg
1 parent ddbaa5b commit 1aad214

File tree

14 files changed

+245
-55
lines changed

14 files changed

+245
-55
lines changed

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,5 @@ out/
1515

1616
.java-version
1717
.factorypath
18+
19+
/*.svg

maven-script/maven-plugin-tools-ant/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828

2929
<artifactId>maven-plugin-tools-ant</artifactId>
3030

31-
<name>Maven Plugin Tool for Ant</name>
31+
<name>Maven Plugin Tool for Ant (deprecated)</name>
3232
<description>Descriptor extractor for plugins written in Ant.</description>
3333

3434
<dependencies>

maven-script/maven-plugin-tools-beanshell/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828

2929
<artifactId>maven-plugin-tools-beanshell</artifactId>
3030

31-
<name>Maven Plugin Tool for Beanshell</name>
31+
<name>Maven Plugin Tool for Beanshell (deprecated)</name>
3232
<description>Descriptor extractor for plugins written in Beanshell.</description>
3333

3434
<dependencies>

maven-script/maven-plugin-tools-model/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828

2929
<artifactId>maven-plugin-tools-model</artifactId>
3030

31-
<name>Maven Plugin Metadata Model</name>
31+
<name>Maven Plugin Metadata Model (deprecated)</name>
3232
<description>The Maven Plugin Metadata Model provides an API to play with the Metadata model.</description>
3333

3434
<dependencies>

maven-script/maven-script-ant/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ under the License.
2828

2929
<artifactId>maven-script-ant</artifactId>
3030

31-
<name>Maven Ant Mojo Support</name>
31+
<name>Maven Ant Mojo Support (deprecated)</name>
3232
<description>Maven Ant Mojo Support, ie write Maven plugins with Ant scripts.</description>
3333

3434
<dependencies>

maven-script/maven-script-beanshell/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ under the License.
2828

2929
<artifactId>maven-script-beanshell</artifactId>
3030

31-
<name>Maven Beanshell Mojo Support</name>
31+
<name>Maven Beanshell Mojo Support (deprecated)</name>
3232
<description>Maven Beanshell Mojo Support, ie write Maven plugins with Beanshell scripts.</description>
3333

3434
<dependencies>

maven-script/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ under the License.
2929
<artifactId>maven-script</artifactId>
3030
<packaging>pom</packaging>
3131

32-
<name>Maven Script Mojo Support</name>
32+
<name>Maven Script Mojo Support (deprecated)</name>
3333
<description>Maven Script Mojo Support lets developer write Maven plugins/goals with scripting languages instead of compiled Java. Scripting support is deprecated, with Maven 4 only Java based Mojos will be supported.</description>
3434

3535
<modules>

pom.xml

+2-1
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,8 @@
342342
<artifactId>apache-rat-plugin</artifactId>
343343
<configuration>
344344
<excludes combine.children="append">
345-
<exclude>src/site/resources/images/plugin-descriptors.svg</exclude>
345+
<exclude>src/site/resources/images/*.svg</exclude>
346+
<exclude>*.svg</exclude>
346347
<!-- Jenkins job with local Maven repository -->
347348
<exclude>src/site/xdoc/plugin-descriptors.mmd</exclude>
348349
<!-- Hudson Maven3 integration log -->

prepare-svg.sh

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
#!/bin/bash
2+
3+
# Licensed to the Apache Software Foundation (ASF) under one
4+
# or more contributor license agreements. See the NOTICE file
5+
# distributed with this work for additional information
6+
# regarding copyright ownership. The ASF licenses this file
7+
# to you under the Apache License, Version 2.0 (the
8+
# "License"); you may not use this file except in compliance
9+
# with the License. You may obtain a copy of the License at
10+
#
11+
# http://www.apache.org/licenses/LICENSE-2.0
12+
#
13+
# Unless required by applicable law or agreed to in writing,
14+
# software distributed under the License is distributed on an
15+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16+
# KIND, either express or implied. See the License for the
17+
# specific language governing permissions and limitations
18+
# under the License.
19+
20+
#libreoffice --headless --convert-to svg src/xdoc/plugin-tools-deps.odg
21+
# CLI export keeps full A3 page
22+
# I prefer doing it by hand, limiting export to "selection" = avoids extra space
23+
24+
# svgo https://github.com/svg/svgo
25+
svgo --config svgo.config.mjs plugin-tools-deps.svg -o plugin-tools-deps-optimized.svg
26+
27+
cat plugin-tools-deps-optimized.svg \
28+
| sed 's/a xlink:href/a target="_parent" xlink:href/' \
29+
| sed 's_file://_.._' \
30+
> src/site/resources/images/plugin-tools-deps.svg
-46.2 KB
Binary file not shown.
Loading

src/site/xdoc/index.xml

+5-48
Original file line numberDiff line numberDiff line change
@@ -37,28 +37,8 @@
3737
help, and documentation.</p>
3838

3939
<p>
40-
<img src="images/plugin-tools-deps.png" width="759" height="474" border="0" usemap="#PluginTools_dependencies" />
41-
<map name="PluginTools_dependencies">
42-
<area shape="rect" coords="256,0,467,34" alt="maven-plugin-plugin" href="./maven-plugin-plugin" />
43-
<area shape="rect" coords="28,95,205,131" alt="plugin-tools-api" href="./maven-plugin-tools-api"/>
44-
<area shape="rect" coords="287,154,496,190" alt="plugin-tools-javadoc" href="./maven-plugin-tools-javadoc"/>
45-
<area shape="rect" coords="44,146,508,198" alt="plugin-tools-java" href="./maven-plugin-tools-java"/>
46-
<area shape="rect" coords="311,213,496,248" alt="plugin-annotations" href="./maven-plugin-annotations"/>
47-
<area shape="rect" coords="44,204,508,256" alt="plugin-tools-annotations" href="./maven-plugin-tools-annotations"/>
48-
<area shape="rect" coords="55,270,293,306" alt="plugin-tools-beanshell" href="./maven-script/maven-plugin-tools-beanshell"/>
49-
<area shape="rect" coords="319,271,557,306" alt="maven-script-beanshell" href="./maven-script/maven-script-beanshell"/>
50-
<area shape="rect" coords="56,329,223,365" alt="plugin-tools-ant" href="./maven-script/maven-plugin-tools-ant"/>
51-
<area shape="rect" coords="388,329,557,365" alt="maven-script-ant" href="./maven-script/maven-script-ant"/>
52-
<area shape="rect" coords="48,388,231,424" alt="plugin-tools-model" href="./maven-script/maven-plugin-tools-model"/>
53-
<area shape="rect" coords="514,95,759,131" alt="plugin-tools-generators" href="./maven-plugin-tools-generators"/>
54-
<area shape="rect" coords="44,263,570,432" alt="maven-script" href="./maven-script"/>
55-
<area shape="rect" coords="340,438,529,474" alt="maven-plugin-api" href="/ref/current/maven-plugin-api/"/>
56-
<area shape="rect" coords="510,154,582,190" alt="qdox" href="https://github.com/paul-hammant/qdox"/>
57-
<area shape="rect" coords="510,212,583,248" alt="asm" href="https://asm.ow2.org/"/>
58-
<area shape="rect" coords="656,134,747,169" alt="Doxia" href="/doxia/"/>
59-
<area shape="rect" coords="599,271,715,306" alt="Beanshell" href="http://www.beanshell.org/"/>
60-
<area shape="rect" coords="600,329,670,366" alt="Ant" href="https://ant.apache.org/"/>
61-
</map>
40+
<object type="image/svg+xml" data="images/plugin-tools-deps.svg" width="643" height="284">
41+
</object>
6242
</p>
6343

6444
<table>
@@ -83,10 +63,6 @@
8363
<td>&nbsp;&nbsp;<a href="./maven-plugin-tools-java/index.html">maven-plugin-tools-java</a></td>
8464
<td>Extractor for plugins written in Java annotated with Mojo Javadoc Tags.</td>
8565
</tr>
86-
<tr>
87-
<td>&nbsp;&nbsp;&nbsp;&nbsp;<a href="./maven-plugin-tools-javadoc/index.html">maven-plugin-tools-javadoc</a></td>
88-
<td>Provides doclets to support Mojo Javadoc Tags in the Javadoc Tool.</td>
89-
</tr>
9066
<tr>
9167
<td>&nbsp;&nbsp;<a href="./maven-plugin-tools-annotations/index.html">maven-plugin-tools-annotations</a></td>
9268
<td>Extractor for plugins written in Java with Java annotations.</td>
@@ -96,28 +72,9 @@
9672
<td>Provides the Java annotations to use in Mojos.</td>
9773
</tr>
9874
<tr>
99-
<td><a href="./maven-script/index.html">maven-script</a></td>
100-
<td>Maven Script Mojo Support lets developer write Maven plugins/goals with scripting languages instead of compiled Java.</td>
101-
</tr>
102-
<tr>
103-
<td>&nbsp;&nbsp;<a href="./maven-script/maven-plugin-tools-beanshell/index.html">maven-plugin-tools-beanshell</a></td>
104-
<td>Extractor for plugins written in Beanshell.</td>
105-
</tr>
106-
<tr>
107-
<td>&nbsp;&nbsp;<a href="./maven-script/maven-script-beanshell/index.html">maven-script-beanshell</a></td>
108-
<td>Maven Beanshell Mojo Support, ie write Maven plugins with Beanshell scripts.</td>
109-
</tr>
110-
<tr>
111-
<td>&nbsp;&nbsp;<a href="./maven-script/maven-plugin-tools-ant/index.html">maven-plugin-tools-ant</a></td>
112-
<td>Extractor for plugins written in Ant.</td>
113-
</tr>
114-
<tr>
115-
<td>&nbsp;&nbsp;<a href="./maven-script/maven-script-ant/index.html">maven-script-ant</a></td>
116-
<td>Maven Ant Mojo Support, ie write Maven plugins with Ant script.</td>
117-
</tr>
118-
<tr>
119-
<td>&nbsp;&nbsp;<a href="./maven-script/maven-plugin-tools-model/index.html">maven-plugin-tools-model</a></td>
120-
<td>Plugin Metadata Model for script-based plugins.</td>
75+
<td><a href="./maven-script/index.html">maven-script</a> (deprecated)</td>
76+
<td>Maven Script Mojo Support lets developer write Maven plugins/goals with scripting languages instead of compiled Java.<br/>
77+
Deprecated since 3.7.0</td>
12178
</tr>
12279
</table>
12380

src/site/xdoc/plugin-tools-deps.odg

-6.2 KB
Binary file not shown.

svgo.config.mjs

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
/*
2+
* Licensed to the Apache Software Foundation (ASF) under one
3+
* or more contributor license agreements. See the NOTICE file
4+
* distributed with this work for additional information
5+
* regarding copyright ownership. The ASF licenses this file
6+
* to you under the Apache License, Version 2.0 (the
7+
* "License"); you may not use this file except in compliance
8+
* with the License. You may obtain a copy of the License at
9+
*
10+
* http://www.apache.org/licenses/LICENSE-2.0
11+
*
12+
* Unless required by applicable law or agreed to in writing,
13+
* software distributed under the License is distributed on an
14+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15+
* KIND, either express or implied. See the License for the
16+
* specific language governing permissions and limitations
17+
* under the License.
18+
*/
19+
20+
export default {
21+
js2svg: {
22+
indent: 1,
23+
pretty: true,
24+
},
25+
plugins: [
26+
'preset-default',
27+
{
28+
name: "removeAttrs",
29+
params: {
30+
attrs: [
31+
"g:class",
32+
"path:class",
33+
]
34+
}
35+
},
36+
],
37+
};

0 commit comments

Comments
 (0)