Changes for page Home

Last modified by Benjamin Fischer on 2025/06/04 14:20

From version 99.2
edited by Benjamin Fischer
on 2025/01/14 14:21
Change comment: There is no comment for this version
To version 112.6
edited by Benjamin Fischer
on 2025/05/15 13:20
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -7,6 +7,8 @@
7 7  
8 8  //{{icon name="info-circle"/}}//ErUM =** Er**forschung von** U**niversum & **M**aterie
9 9  (Research on Universe and Matter)
10 +
11 +
10 10  {{/box}}
11 11  
12 12  == **Welcome** ==
... ... @@ -18,19 +18,22 @@
18 18  **We invite you to create an account and contribute improvements and contents yourself. For help, see this [[video>>attach:registration.mp4]]. **
19 19  
20 20  
21 -This wiki will be launched and released for use in January 2025. Please note that further development is an ongoing effort. Further functions, content and interaction options are planned. **This wiki is for you, the ErUM-Data community**, and is intended to meet your needs. For optimal functionality, we are dependent on your input. We are always happy to receive feedback, suggestions and requests, which you are welcome to send to angela.warkentin@erumdatahub.de.
23 +This wiki was launched and released for use in January 2025. Please note that further development is an ongoing effort. Further functions, content and interaction options are planned. **This wiki is for you, the ErUM-Data community**, and is intended to meet your needs. For optimal functionality, we are dependent on your input. We are always happy to receive feedback, suggestions and requests, which you are welcome to send to angela.warkentin@erumdatahub.de.
22 22  
23 23  ==== ====
24 24  
25 -{{icon name="question-circle"}}{{/icon}}Further information, answers to all questions you may have regarding the ErUM-Data-Hub and more about our aims and work can be found on our [[website>>https://erumdatahub.de/]].
27 +{{icon name="question-circle"}}{{/icon}}Further information, answers to all questions you may have regarding the ErUM-Data-Hub and more about our aims and work can be found on our [[website>>https://erumdatahub.de/]]
26 26  
27 27  
30 +
31 +
28 28  == What is new? ==
29 29  
30 -Have a look at our new comprehensive material collection and People in ErUM-Data list:
34 +Have a look at our new comprehensive material collection, the People in ErUM-Data list and Industry meets ErUM-Data:
31 31  
32 32  * [[Material collection]] of learning and teaching materials, and
33 -* [[People in ErUM-Data]] list of research groups and contact information of people who work in ErUM-Data.
37 +* [[People in ErUM-Data]] list of research groups and contact information of people who work in ErUM-Data
38 +* [[Industry meets ErUM-Data >>doc:Industry meets ErUM-Data.WebHome]]collection of various groups in industry that are adjacent or in cooperation with ErUM-Data science
34 34  
35 35  = =
36 36  
Gewinnspiel Wiki(1).jpg
Author
... ... @@ -1,0 +1,1 @@
1 +XWiki.JudithSteinfeld
Size
... ... @@ -1,0 +1,1 @@
1 +3.5 MB
Content
XWiki.JavaScriptExtension[0]
Code
... ... @@ -27,7 +27,7 @@
27 27  
28 28   const ys = this.start;
29 29   const ye = this.end;
30 - const yv = events.slice().sort((a,b) => a.start.diff(b.start) || a.end.diff(b.end));
30 + const yv = events.slice().sort((a, b) => a.start.diff(b.start) || a.end.diff(b.end));
31 31  
32 32   const cols = [];
33 33   const head = [];
... ... @@ -34,21 +34,21 @@
34 34   const days = Array(31).fill().map(_ => []);
35 35  
36 36   if (rf) {
37 - cols.push(E("col", {class: "fc-fitCol"}));
37 + cols.push(E("col", { class: "fc-fitCol" }));
38 38   head.push(E("th"));
39 - days.forEach((arr, day) => arr.push(E("th", {class: "fc-axis"}, ys.clone().add({day}).format(rf))));
39 + days.forEach((arr, day) => arr.push(E("th", { class: "fc-axis" }, ys.clone().add({ day }).format(rf))));
40 40   }
41 41  
42 42   for (const month of range(12)) {
43 - const ms = ys.clone().add({month})
44 - const me = ms.clone().add({month: 1});
43 + const ms = ys.clone().add({ month })
44 + const me = ms.clone().add({ month: 1 });
45 45   const md = me.diff(ms, "days");
46 46   const mv = yv.filter(t => ms.isBefore(t.end) && t.start.isBefore(me));
47 47  
48 - if (df) cols.push(E("col", {class: "fc-fitCol"}));
48 + if (df) cols.push(E("col", { class: "fc-fitCol" }));
49 49   cols.push(E("col"));
50 - if (wf) cols.push(E("col", {class: "fc-fitCol"}));
51 - head.push(E("th", {colspan}, ms.format(cf)));
50 + if (wf) cols.push(E("col", { class: "fc-fitCol" }));
51 + head.push(E("th", { colspan }, ms.format(cf)));
52 52  
53 53   const bgc = new Array(md);
54 54   const bgt = new Array(md);
... ... @@ -62,11 +62,11 @@
62 62  
63 63   for (const day of range(31)) {
64 64   if (day < md) {
65 - const ds = ms.clone().add({day});
66 - const de = ds.clone().add({day: 1});
65 + const ds = ms.clone().add({ day });
66 + const de = ds.clone().add({ day: 1 });
67 67  
68 68   const oc = [];
69 - while(mv[0]?.start.isBefore(de)) {
69 + while (mv[0]?.start.isBefore(de)) {
70 70   const v = mv.shift();
71 71   const d = Math.ceil(v.end.max(me).diff(ds, "days", true));
72 72   if (v.rendering == "background") {
... ... @@ -76,7 +76,7 @@
76 76   bgt[day + i] = v.title;
77 77   }
78 78   } else {
79 - const e = E("div", E("a", {href: v.url}, v.title));
79 + const e = E("div", E("a", { href: v.url }, v.title));
80 80   e.style.height = `${100 * d}%`;
81 81   if (v.color) e.style.borderColor = e.style.backgroundColor = v.color;
82 82   if (v.textColor) e.style.color = v.textColor;
... ... @@ -97,16 +97,16 @@
97 97   }
98 98  
99 99   scu = scu.map(u => Math.max(0, u - 1));
100 - if (!scu.some()) {scc = []; scu = [];}
100 + if (!scu.some()) { scc = []; scu = []; }
101 101  
102 102   const style = bgc[day] && `background-color: ${bgc[day]};`;
103 103   const dc = this.getDayClasses(ds);
104 - const da = (sub, title = bgt[day] ?? null) => ({class: dc.concat(sub).join(" "), style, title});
104 + const da = (sub, title = bgt[day] ?? null) => ({ class: dc.concat(sub).join(" "), style, title });
105 105   if (df) days[day].push(E("td", da("fc-dayVal", ds.format("D")), ds.format(df)));
106 106   days[day].push(E("td", da("fc-mainVal"), oc));
107 107   if (wf) days[day].push(E("td", da("fc-weekVal"), ds.weekday() ? "" : ds.format(wf)));
108 108   } else
109 - days[day].push(E("td", {colspan}));
109 + days[day].push(E("td", { colspan }));
110 110   }
111 111   }
112 112  
... ... @@ -115,8 +115,8 @@
115 115   E(
116 116   "table",
117 117   E("colgroup", cols),
118 - E("thead", {class: "fc-head"}, E("tr", head)),
119 - E("tbody", {class: "fc-body"}, days.map(d => E("tr", d))),
118 + E("thead", { class: "fc-head" }, E("tr", head)),
119 + E("tbody", { class: "fc-body" }, days.map(d => E("tr", d))),
120 120   )
121 121   );
122 122   }
... ... @@ -125,52 +125,54 @@
125 125   });
126 126  
127 127   const init = () => {
128 - jq("#calendarCustom").fullCalendar({
129 - views: {
130 - month: {
131 - columnFormat: "ddd",
132 - titleFormat: "MMMM YYYY",
133 - buttonText: "month",
128 + const cal = jq("#calendarCustom");
129 + if (cal.length)
130 + cal.fullCalendar({
131 + views: {
132 + month: {
133 + columnFormat: "ddd",
134 + titleFormat: "MMMM YYYY",
135 + buttonText: "month",
136 + },
137 + monthCols: {
138 + columnFormat: "MMM",
139 + weekFormat: "W",
140 + titleFormat: "YYYY",
141 + buttonText: "year",
142 + },
134 134   },
135 - monthCols: {
136 - columnFormat: "MMM",
137 - weekFormat: "W",
138 - titleFormat: "YYYY",
139 - buttonText: "year",
144 + timeFormat: "h(:mm)t",
145 + axisFormat: "h(:mm)t",
146 + allDayText: "All day",
147 + eventSources: [
148 + "/bin/get/MoccaCalendar/Code/JSONService?xpage=plain&outputSyntax=plain&calendarDoc=Main.WebHome&filter=wiki&classname=MoccaCalendar.MoccaCalendarEventClass&startfield=startDate&endfield=endDate&durationfield=&xpage=plain&outputSyntax=plain&classname=&startfield=datetime&endfield=&durationfield=&extraFields=",
149 + ],
150 + header: {
151 + left: "prev,next today",
152 + center: "title",
153 + right: "month,monthCols",
140 140   },
141 - },
142 - timeFormat: "h(:mm)t",
143 - axisFormat: "h(:mm)t",
144 - allDayText: "All day",
145 - eventSources: [
146 - "/bin/get/MoccaCalendar/Code/JSONService?xpage=plain&outputSyntax=plain&calendarDoc=Main.WebHome&filter=wiki&classname=MoccaCalendar.MoccaCalendarEventClass&startfield=startDate&endfield=endDate&durationfield=&xpage=plain&outputSyntax=plain&classname=&startfield=datetime&endfield=&durationfield=&extraFields=",
147 - ],
148 - header: {
149 - left: "prev,next today",
150 - center: "title",
151 - right: "month,monthCols",
152 - },
153 - timeFormat: "H:mm",
154 - defaultView: "monthCols",
155 - firstDay: "1",
156 - minTime: "8:00",
157 - maxTime: "23:00",
158 - validRange: {
159 - start: '2022-01-01',
160 - end: '2027-01-01',
161 - },
162 - editable: false,
163 - eventDataTransform: event => {
164 - const cal = event.url.split("/")[4];
165 - if (cal === "Holidays" || cal == "Blocked" || cal.includes("Conference")) event.rendering = "background";
166 - event.viewUrl = event.url;
167 - event.url = event.html.match(/<span class="wikiexternallink"><a href="([^"]+)">\1</)?.[1] ?? event.url;
168 - return event;
169 - },
170 - eventRender: function (event, element) {
171 - // Render augmentation hook, use: event.html
172 - },
173 - });
155 + timeFormat: "H:mm",
156 + defaultView: "monthCols",
157 + firstDay: "1",
158 + minTime: "8:00",
159 + maxTime: "23:00",
160 + validRange: {
161 + start: '2022-01-01',
162 + end: '2027-01-01',
163 + },
164 + editable: false,
165 + eventDataTransform: event => {
166 + const cal = event.url.split("/")[4];
167 + if (cal === "Holidays" || cal == "Blocked" || cal.includes("Conference")) event.rendering = "background";
168 + event.viewUrl = event.url;
169 + event.url = event.html.match(/<span class="wikiexternallink"><a href="([^"]+)">\1</)?.[1] ?? event.url;
170 + return event;
171 + },
172 + eventRender: function (event, element) {
173 + // Render augmentation hook, use: event.html
174 + },
175 + });
174 174   };
175 175  
176 176   jq(document).ready(init);
Use this extension
... ... @@ -1,1 +1,1 @@
1 -onDemand
1 +currentPage
XWiki.JavaScriptExtension[1]
Caching policy
... ... @@ -1,0 +1,1 @@
1 +default
Code
... ... @@ -1,0 +1,79 @@
1 +define("xwiki-custom-livetable", [], function () {
2 + const func = (tabName, rowFunc, colTT = {}) => {
3 + let tagCols;
4 +
5 + document.observe('xwiki:livetable:loading', () => {
6 + const tab = document.getElementById(tabName);
7 + if (!tab) return;
8 +
9 + // coulmn data sources
10 + const conf = JSON.parse(tab.dataset.settings);
11 + tagCols = (conf.columnDescriptors.tags ?? { aux: [] }).aux ?? [["Tags", true]];
12 + tagCols.forEach(([name], i) => {
13 + const cn = `tags-${i}`;
14 + conf.columns.splice(conf.columns.indexOf("tags"), 1, cn);
15 + conf.columnDescriptors[cn] = {
16 + displayName: name,
17 + headerClass: "tagsCol",
18 + html: true,
19 + sortable: false,
20 + };
21 + });
22 + tab.dataset.settings = JSON.stringify(conf);
23 +
24 + // column headers
25 + tab.querySelectorAll(".xwiki-livetable-display-header .tagsCol").forEach(
26 + (v, i) => v.textContent = tagCols[i][0]
27 + );
28 +
29 + // column tooltips
30 + tab.querySelectorAll(".xwiki-livetable-display-header-text").forEach(
31 + el => {
32 + const t = el.textContent.trim();
33 + const c = conf.columnDescriptors[t].tooltip ?? colTT[t];
34 + if (c) {
35 + el.title = t;
36 + el.dataset.content = c;
37 + el.dataset.toggle = "popover";
38 + el.dataset.placement = "top";
39 + }
40 + }
41 + )
42 +
43 + // handle clicks for tags
44 + document.getElementById(`${tabName}-display`).addEventListener("click", ev => {
45 + if (ev.button) return; // only left click
46 + if (ev.target.nodeName !== "SPAN") return;
47 + if (!ev.target.classList.contains("ltTag")) return;
48 + const tag = ev.target.textContent;
49 + ev.preventDefault();
50 + const lt = tab.__liveTable;
51 + const st = lt.tagCloud.selectedTags;
52 + if (tag in st) delete st[tag];
53 + else st[tag] = {};
54 + lt.tags = Object.keys(st);
55 + lt.clearCache();
56 + lt.showRows(1, lt.limit);
57 + })
58 + });
59 +
60 + document.observe(`xwiki:livetable:${tabName}:receivedEntries`, ({ memo: { data } }) => {
61 + for (const row of data.rows) {
62 + if (rowFunc) rowFunc(row)
63 +
64 + // tags
65 + const tags = new Set(row.tags_value.slice(1, -1).split(", "));
66 + tagCols.forEach(([name, ...want], i) =>
67 + row[`tags-${i}`] = (
68 + want[0] === true
69 + ? Array.from(tags)
70 + : want.filter(tag => tags.delete(tag))
71 + ).sort().map(tag => `<span class="ltTag" style="cursor:pointer;">${tag}</span>`).join(", ")
72 + );
73 + }
74 + });
75 + };
76 +
77 + func.func = func;
78 + return func;
79 +});
Name
... ... @@ -1,0 +1,1 @@
1 +Livetable - Common Stuff
Parse content
... ... @@ -1,0 +1,1 @@
1 +No
Use this extension
... ... @@ -1,0 +1,1 @@
1 +always