Skip to content

Commit 14ff9f3

Browse files
committed
fix: update selector operators
1 parent 70ed42f commit 14ff9f3

File tree

1 file changed

+140
-140
lines changed

1 file changed

+140
-140
lines changed

demo/index.html

Lines changed: 140 additions & 140 deletions
Original file line numberDiff line numberDiff line change
@@ -1,156 +1,156 @@
11
<!DOCTYPE html>
22
<html lang="en">
3-
<head>
4-
<title>Clone | CoCreateJS</title>
5-
<!-- CoCreate Favicon -->
6-
<link
7-
rel="icon"
8-
type="image/png"
9-
sizes="32x32"
10-
href="../assets/favicon.ico" />
3+
<head>
4+
<title>Clone | CoCreateJS</title>
5+
<!-- CoCreate Favicon -->
6+
<link
7+
rel="icon"
8+
type="image/png"
9+
sizes="32x32"
10+
href="../assets/favicon.ico" />
1111

12-
<style>
13-
.stage {
14-
background-color: gray;
15-
margin: 15px;
16-
padding-top: 10px;
17-
}
12+
<style>
13+
.stage {
14+
background-color: gray;
15+
margin: 15px;
16+
padding-top: 10px;
17+
}
1818

19-
.card {
20-
background-color: beige;
21-
margin: 15px;
22-
min-height: 100px;
23-
}
19+
.card {
20+
background-color: beige;
21+
margin: 15px;
22+
min-height: 100px;
23+
}
2424

25-
.tasklist {
26-
background-color: lightgray;
27-
margin: 15px;
28-
}
25+
.tasklist {
26+
background-color: lightgray;
27+
margin: 15px;
28+
}
2929

30-
span {
31-
display: inline-block;
32-
}
33-
.template {
34-
display: none;
35-
}
36-
</style>
37-
<link rel="manifest" href="/manifest.webmanifest" />
38-
</head>
30+
span {
31+
display: inline-block;
32+
}
33+
.template {
34+
display: none;
35+
}
36+
</style>
37+
<link rel="manifest" href="/manifest.webmanifest" />
38+
</head>
3939

40-
<body>
41-
<a actions="clone" clone-selector="next; .stage[template]">New Stage</a>
42-
<!--<div id="saveFetch1" -->
43-
<!-- class="domEditor" -->
44-
<!-- key='clonehtml7' -->
45-
<!-- array="module_activity124" -->
46-
<!-- object="5fbd3b198b0e4d7391255615" -->
47-
<!-- state_id="me1234">-->
40+
<body>
41+
<a actions="clone" clone-selector="$next .stage[template]">New Stage</a>
42+
<!--<div id="saveFetch1" -->
43+
<!-- class="domEditor" -->
44+
<!-- key='clonehtml7' -->
45+
<!-- array="module_activity124" -->
46+
<!-- object="5fbd3b198b0e4d7391255615" -->
47+
<!-- state_id="me1234">-->
4848

49-
<div class="Sortable">
50-
<div class="Sortable stage" style="padding: 15px" template>
51-
<span style="color: #fff; font-size: 20px" class="noDrag"
52-
>Stage</span
53-
>
54-
<span style="float: right">
55-
<a actions="remove" remove-closest=".stage" class="noDrag"
56-
><i class="height:18px" src="/assets/svg/times.svg"></i
57-
></a>
58-
</span>
49+
<div class="Sortable">
50+
<div class="Sortable stage" style="padding: 15px" template>
51+
<span style="color: #fff; font-size: 20px" class="noDrag"
52+
>Stage</span
53+
>
54+
<span style="float: right">
55+
<a actions="remove" remove-closest=".stage" class="noDrag"
56+
><i class="height:18px" src="/assets/svg/times.svg"></i
57+
></a>
58+
</span>
5959

60-
<div class="Sortable" dnd-group-key="cards">
61-
<div class="card" style="padding: 15px" template>
62-
<span class="noDrag">Card</span>
63-
<span style="float: right">
64-
<a
65-
actions="remove"
66-
remove-closest=".card"
67-
class="noDrag"
68-
><i
69-
class="height:18px"
70-
src="/assets/svg/times.svg"></i
71-
></a>
72-
</span>
60+
<div class="Sortable" dnd-group-key="cards">
61+
<div class="card" style="padding: 15px" template>
62+
<span class="noDrag">Card</span>
63+
<span style="float: right">
64+
<a
65+
actions="remove"
66+
remove-closest=".card"
67+
class="noDrag"
68+
><i
69+
class="height:18px"
70+
src="/assets/svg/times.svg"></i
71+
></a>
72+
</span>
7373

74-
<div class="Sortable" dnd-group-key="tasklist">
75-
<div class="tasklist" template>
76-
<span class="noDrag">Tasklist</span>
77-
<span style="float: right">
78-
<a
79-
actions="remove"
80-
remove-closest=".tasklist"
81-
class="noDrag"
82-
><i
83-
class="height:18px"
84-
src="/assets/svg/times.svg"></i
85-
></a>
86-
</span>
74+
<div class="Sortable" dnd-group-key="tasklist">
75+
<div class="tasklist" template>
76+
<span class="noDrag">Tasklist</span>
77+
<span style="float: right">
78+
<a
79+
actions="remove"
80+
remove-closest=".tasklist"
81+
class="noDrag"
82+
><i
83+
class="height:18px"
84+
src="/assets/svg/times.svg"></i
85+
></a>
86+
</span>
8787

88-
<form
89-
array="module_activity"
90-
class="Sortable"
91-
dnd-group-key="task-itemse"
92-
id="testForm">
93-
<div class="task-item" template>
94-
<!-- <div style="display:inline-block;width: calc(100% - 20px);"> -->
95-
<input
96-
class="floating-label"
97-
object=""
98-
key="taskname"
99-
placeholder="Task Name" />
100-
<!-- </div> -->
101-
<span style="float: right">
102-
<a
103-
actions="remove"
104-
remove-closest=".task-item"
105-
class="deleteBtn noDrag"
106-
><i
107-
class="height:18px"
108-
src="/assets/svg/times.svg"></i
109-
></a>
110-
</span>
111-
</div>
112-
</form>
113-
<a
114-
actions="clone"
115-
clone-parent=".task-item[template]"
116-
class="noDrag"
117-
style="display: block"
118-
>Add Task</a
119-
>
120-
</div>
121-
<!-- Cloneable Tasklist element -->
122-
</div>
123-
<!-- Sortable Tasklist Container -->
88+
<form
89+
array="module_activity"
90+
class="Sortable"
91+
dnd-group-key="task-itemse"
92+
id="testForm">
93+
<div class="task-item" template>
94+
<!-- <div style="display:inline-block;width: calc(100% - 20px);"> -->
95+
<input
96+
class="floating-label"
97+
object=""
98+
key="taskname"
99+
placeholder="Task Name" />
100+
<!-- </div> -->
101+
<span style="float: right">
102+
<a
103+
actions="remove"
104+
remove-closest=".task-item"
105+
class="deleteBtn noDrag"
106+
><i
107+
class="height:18px"
108+
src="/assets/svg/times.svg"></i
109+
></a>
110+
</span>
111+
</div>
112+
</form>
113+
<a
114+
actions="clone"
115+
clone-parent=".task-item[template]"
116+
class="noDrag"
117+
style="display: block"
118+
>Add Task</a
119+
>
120+
</div>
121+
<!-- Cloneable Tasklist element -->
122+
</div>
123+
<!-- Sortable Tasklist Container -->
124124

125-
<a
126-
actions="clone"
127-
clone-parent=".tasklist[template]"
128-
class="noDrag"
129-
style="display: block"
130-
clone-data="{}"
131-
>New Tasklist</a
132-
>
133-
</div>
134-
<!-- Cloneable Card element -->
135-
</div>
136-
<!-- Sortable Card Container -->
125+
<a
126+
actions="clone"
127+
clone-parent=".tasklist[template]"
128+
class="noDrag"
129+
style="display: block"
130+
clone-data="{}"
131+
>New Tasklist</a
132+
>
133+
</div>
134+
<!-- Cloneable Card element -->
135+
</div>
136+
<!-- Sortable Card Container -->
137137

138-
<a
139-
actions="clone"
140-
clone-previous=".card[template]"
141-
class="noDrag"
142-
>New Card</a
143-
>
144-
<input id="card-name" />
145-
</div>
146-
<!-- sortable and clonable stage -->
147-
</div>
148-
<!-- sortable project -->
138+
<a
139+
actions="clone"
140+
clone-previous=".card[template]"
141+
class="noDrag"
142+
>New Card</a
143+
>
144+
<input id="card-name" />
145+
</div>
146+
<!-- sortable and clonable stage -->
147+
</div>
148+
<!-- sortable project -->
149149

150-
<!--</div> -->
150+
<!--</div> -->
151151

152-
<!-- <script src="../dist/CoCreate-clone.js"></script> -->
153-
<!-- <script src="../../../CoCreateJS/dist/CoCreate.js"></script> -->
154-
<script src="https://CoCreate.app/dist/CoCreate.js"></script>
155-
</body>
152+
<!-- <script src="../dist/CoCreate-clone.js"></script> -->
153+
<!-- <script src="../../../CoCreateJS/dist/CoCreate.js"></script> -->
154+
<script src="https://CoCreate.app/dist/CoCreate.js"></script>
155+
</body>
156156
</html>

0 commit comments

Comments
 (0)