Skip to content

Commit 1cbde9b

Browse files
committed
AAL 0.5.02 - many new features
1 parent f416f74 commit 1cbde9b

17 files changed

+507
-87
lines changed

Diff for: FEATURES.md

+1
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ Completed Features are documented here, for context.
4848
What's out there that we want to meet or exceed?
4949

5050
### Mind Maps
51+
5152
* https://en.wikipedia.org/wiki/Mind_map
5253
> A mind map is a diagram used to visually organize information. A mind map is hierarchical and shows relationships among pieces of the whole.[1] It is often created around a single concept, drawn as an image in the center of a blank page, to which associated representations of ideas such as images, words and parts of words are added. Major ideas are connected directly to the central concept, and other ideas branch out from those.
5354

Diff for: LICENSE

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2019 Opentecture
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

Diff for: sandbox/opentecture-bookmarks/add-a-line-bookmarks/README.md

+9
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,20 @@ See also [Opentecture Bookmarks View-a-line Read Me]( https://opentecture.github
3333

3434
## Issues
3535

36+
* 2019-07-06 ~ Theo ~ Get themes working
3637

3738
## Links of Interest
3839

3940
## Change Log
4041

42+
### 2019-07-06 ~ Theo
43+
44+
Add-a-line Bookmarks v 0.5.02
45+
46+
* Add edit button and better comment display to contents list
47+
* Add scraping for data in editing bm
48+
* Working with <TooToo14 class="04"></TooToo14>
49+
4150
### 2019-06-22 ~ Theo
4251

4352
Add-a-line Bookmarks v 0.5.01
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
## dev notes
2+
3+
4+
### 2019-07-07
5+
6+
##
7+
8+
## The problem that needs solving
9+
10+
* You have some knowledge you want to share with others
11+
* Several of you have knowledge you would like to share
12+
13+
14+
### Standing on the shoulders of Giants
15+
16+
* Much of your knowledge is available instantly via links
17+
* Via links to web pages or to ISBN references or online documents
18+
* Your links are selected, prioritized and commented
19+
* The collection of links together may be considered to form an authoritative view of the topic in question
20+
* The content at the link destinations generally follow [Wikipedia Core Content Policies]( https://en.wikipedia.org/wiki/Wikipedia:Core_content_policies )
21+
* Neutral Point of View
22+
* Verifiability
23+
* No original research
24+
25+
26+
### Sharing
27+
28+
* The knowledge in each link must be made availble with a click or twp
29+
* No paywalls
30+
* Much of the knowledge is available in small chunks
31+
* Just-in-time learning
32+
* Examples include most Wikipedia articles and Khan Academy's three minute videos
33+
34+
35+
### Simplicity
36+
37+
* Easy code
38+
* Easy data format
39+
40+
41+
### Freedom of display
42+
43+
* Standard two panel trees
44+
* 2D mind maps
45+
* 3D mind maps
46+
47+
48+
### Vision
49+
50+
* Within a few hours you can gain a reasonable overview of the topic at hand
51+
* Its concepts
52+
* Features and benefits
53+
* Current issues
54+
* Major persons involved
55+
* General directions
56+
* [Sun Tzu]( https://medium.com/wardleymaps/on-being-lost-2ef5f05eb1ec ): purpose, landscape, climate, doctrine and leadership
57+
* You are able to act and make decisions using your new knowledge
58+
59+
### Longer term vision
60+
61+
* You may fork the data
62+
* You may add and edit the content and comments

Diff for: sandbox/opentecture-bookmarks/add-a-line-bookmarks/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<body>
77
<script>
88

9-
window.location.href = './v-0-5-01/add-a-line-bookmarks.html' + location.hash;
9+
window.location.href = './v-0-5-02/add-a-line-bookmarks.html' + location.hash;
1010

1111
</script>
1212
</body>

Diff for: sandbox/opentecture-bookmarks/add-a-line-bookmarks/v-0-5-02/README.md

+19-3
Original file line numberDiff line numberDiff line change
@@ -14,29 +14,45 @@ Basic bookmark manager
1414

1515
<summary>To Do / Wish List</summary>
1616

17+
* 2019-07-07 ~ Theo ~ Create tag chains usable to tie Mind Map elements
1718
* 2019-06-23 ~ Theo ~ Filter by multiple tags
1819
* 2019-06-23 ~ Theo ~ Filter by content
1920
* 2019-06-23 ~ Theo ~ Add tags to multiple bookmarks at same time
2021
* 2019-06-23 ~ Theo ~ Refresh memory after a deletion
2122
* 2019-06-23 ~ Theo ~ meta tags with description of entire project, copyright, license etc
2223
* 2019-06-03 ~ Theo ~ Save to and read from gists
23-
* 2019-06-03 ~ Theo ~ Remove dead links
24+
* 2019-06-03 ~ Theo ~ Remove dead links/ or retrieve version from Internet Archive
2425

2526
</details>
2627

2728
<details>
2829

2930
<summary>Issues</summary>
3031

31-
* 2019-06-23 ~ Theo ~ Adding commenys broken?
32-
* 2019-06-23 ~ Theo ~ Add comments by url instead of bookmark id - or keep both?
3332

3433
</details>
3534

3635
<details>
3736

3837
<summary>Change Log</summary>
3938

39+
### 2019-07-07 ~ Theo
40+
41+
Add-a-line Bookmarks v0.5.02
42+
43+
Content
44+
45+
* F - BM.js: Add item numbers and date update
46+
* F - MET.js: first commit
47+
* F - AAL: Update popup text, add license and link
48+
49+
50+
Dealt with
51+
52+
* 2019-06-23 ~ Theo ~ Adding comment broken?
53+
* 2019-06-23 ~ Theo ~ Add comments by url instead of bookmark id - or keep both?
54+
55+
4056
### 2019-06-23 ~ Theo
4157

4258
* Many fixes / looking even better / almost workable

Diff for: sandbox/opentecture-bookmarks/add-a-line-bookmarks/v-0-5-02/add-a-line-bookmarks.html

+9-6
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
.container > div > textarea { height: 5rem; width: 100% }
3434
.container4 > div > input { width: 100% }
3535

36-
#TAGtxtJson, #BMEtxtJson, #COMtxtJson { height: 10rem; width: 100%; }
36+
#TAGtxtJson, #BMEtxtJson, #COMtxtJson, #METtxtJson { height: 10rem; width: 100%; }
3737

3838
#BMNdivDrop { border: 1px dotted #aaaaaa; height: 3rem; padding: 1rem; width: 100%; }
3939

@@ -62,8 +62,10 @@
6262

6363
<!-- Edit Menu -->
6464

65-
<!-- Settings menu -->
66-
<script src = "https://pushme-pullyou.github.io/tootoo14/js-14-04/thm-theme/thm-theme.js" ></script>
65+
<!-- Settings menu
66+
67+
<script src = "https://pushme-pullyou.github.io/tootoo14/js-14-04/thm-theme/thm-theme.js" ></script>
68+
-->
6769
<script src = "https://pushme-pullyou.github.io/tootoo14/js-14-04/tmp-template/tmp-template.js" ></script>
6870

6971
<script src = "js/bm-bookmarks.js" ></script>
@@ -72,6 +74,7 @@
7274
<script src = "js/tga-tags-add.js" ></script>
7375
<script src = "js/tag-tags.js" ></script>
7476
<script src = "js/com-comments.js" ></script>
77+
<script src = "js/met-meta.js" ></script>
7578

7679
<script src = "js/bdm-bookmarks-by-domain.js" ></script>
7780
<script src = "js/btg-bookmarks-by-tag.js" ></script>
@@ -242,16 +245,16 @@ <h1 onclick="navPanel.scrollTop=0;" style="cursor:pointer;text-align:center;" ti
242245

243246
document.body.addEventListener( 'FOBonJsonFileLoad', BM.onLoad, false );
244247

245-
246248
POP.init();
247249

248250
//COR.init();
249251

250252
POP.setPopupShowHide( butPopupClose, "popup.md" );
251253

252254
butPopupClose.classList.remove( 'active' );
253-
main.addEventListener( 'click', POP.onClickClose, false );
254-
main.addEventListener( 'touchstart', POP.onClickClose, false );
255+
256+
//main.addEventListener( 'click', POP.onClickClose, false );
257+
//main.addEventListener( 'touchstart', POP.onClickClose, false );
255258

256259
//BMNdivDrop.addEventListener( "input", BMN.onInput, false);
257260

Diff for: sandbox/opentecture-bookmarks/add-a-line-bookmarks/v-0-5-02/js/bm-bookmarks.js

+30-33
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,11 @@ BM.onLoad = function() {
3333
}
3434
//console.log( 'BM.jsonLines', BM.jsonLines.length );
3535

36+
const metatags = BM.lines.filter( line => line.includes( `"type":"meta"` ) );
37+
//console.log( 'metatags', metatags );
38+
39+
BM.metatags = metatags.map( metatag => JSON.parse( metatag ) ) || [];
40+
3641
BM.setBookmarks();
3742

3843

@@ -45,14 +50,22 @@ BM.setBookmarks = function ( bookmarks = BM.jsonLines ) {
4550
const a = document.createElement( 'a' );
4651
const subdomains = ["www.", "m.", "en." ];
4752

48-
htm = `<h1>Bookmarks from: ${ FOB.urlDefaultFile }</h1>`;
53+
const title = BM.metatags.find( meta => meta.tags.includes( "title" ) ).text || "title";
54+
const subtitle = BM.metatags.find( meta => meta.tags.includes( "subtitle" ) ).text || "subtitle";
55+
const copyright = BM.metatags.find( meta => meta.tags.includes( "copyright" ) ).text || "copyright";
56+
const license = BM.metatags.find( meta => meta.tags.includes( "license" ) ).text || "license";
57+
58+
let htm =
59+
`<h1>${ title }</h1>
60+
<p><i>${ subtitle }. ${copyright }. ${ license }.</i></p>`;
4961

5062
const comments = BM.lines.filter( line => line.includes( `"type":"comment"` ) );
5163
//console.log( 'comments', comments );
5264

5365
BM.comments = comments.map( comment => JSON.parse( comment ) ) || [];
5466

55-
bookmarks.forEach( (bookmark ) => {
67+
count = 1;
68+
bookmarks.forEach( bookmark => {
5669

5770
if ( bookmark.type === "url" ) {
5871

@@ -72,14 +85,17 @@ BM.setBookmarks = function ( bookmarks = BM.jsonLines ) {
7285

7386
htm +=
7487
`<p>
75-
<a href=${bookmark.url } target="_blank" >
88+
${ count++ } <a href=${bookmark.url } target="_blank" >
7689
<img src="${ bookmark.favicon }" height=16px >
7790
<b>${ bookmark.name }</b> - <i>${ site }</i>
7891
</a><br>
79-
tags: <i>${ bookmark.tags }</i> - added: ${ bookmark.dateAdd.slice( 0, 10 ) }<br>
92+
tags: <i>${ bookmark.tags }</i>
93+
- added: ${ bookmark.dateAdd.slice( 0, 10 ) }
94+
- update: ${ bookmark.dateUpdate.slice( 0, 10 ) }
95+
<br>
8096
${ bookmark.description.startsWith ("No description" ) ? "" : bookmark.description }
8197
<p style=color:blue ><button onclick="BM.setContents(${ index });" >edit</button>
82-
${ comment.text ? ( "comment: " + comment.text + " tags: " + comment.tags ) : "" }</p>
98+
${ comment.text ? ( "comment: " + comment.text + " / tags: " + comment.tags ) : "" }</p>
8399
<hr>
84100
</p>`;
85101

@@ -93,35 +109,7 @@ BM.setBookmarks = function ( bookmarks = BM.jsonLines ) {
93109

94110

95111

96-
BM.xxxgetBookmarks = function () {
97-
//console.log( '', FOB.text );
98-
99-
BM.lines = FOB.text.split(/\r\n|\n/);
100-
101-
BM.jsonLines = [];
102-
103-
for ( let line of BM.lines ) {
104-
//console.log( 'line', line );
105-
106-
if ( line.slice( 0, 1 ) !== "{" ) { continue; }
107112

108-
const jsonl = JSON.parse( line );
109-
//console.log( 'jsonl', jsonl );
110-
111-
BM.jsonLines.push( jsonl );
112-
113-
}
114-
115-
const comments = BM.lines.filter( line => line.includes( `"type":"comment"` ) );
116-
//console.log( 'comments', comments );
117-
118-
BM.comments = comments.map( comment => JSON.parse( comment ) ) || [];
119-
120-
//BM.setBookmarks();
121-
122-
BBF.setMenuItemsByUrl();
123-
124-
};
125113

126114

127115

@@ -142,6 +130,8 @@ BM.setContents = function ( index ) {
142130
<div id=TGAdivTagsAdd ></div>
143131
144132
<div id=TAGdivTagSets ></div>
133+
134+
<div id=METdivMetaAdd ></div>
145135
`;
146136

147137
divContents.innerHTML = htm;
@@ -158,6 +148,7 @@ BM.setContents = function ( index ) {
158148

159149
TAGdivTagSets.innerHTML = TAG.getMenuTagSets();
160150

151+
METdivMetaAdd.innerHTML = MET.getMenuMetaAdd();
161152

162153
BM.parseJson( index );
163154

@@ -205,6 +196,12 @@ BM.parseJson = function( index ) {
205196

206197
}
207198

199+
const metatags = BM.lines.filter( line => line.includes( `"type":"meta"` ) );
200+
//console.log( 'metatags', metatags );
201+
202+
BM.metatags = metatags.map( metatag => JSON.parse( metatag ) ) || [];
203+
204+
208205
BMEtxtJson.value = "";
209206
COM.onToggle();
210207

Diff for: sandbox/opentecture-bookmarks/add-a-line-bookmarks/v-0-5-02/js/bme-bookmarks-edit.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ BME.setTextareaJson = function() {
6060
"url": "${ BMinpUrl.value }",
6161
"name": "${ BMinpName.value }",
6262
"dateAdd": "${ BMinpDateAdd.value }",
63-
"dateUpdate": "${ BMinpDateUpdate.value }",
63+
"dateUpdate": "${ new Date().toISOString() }",
6464
"id": "${ BMinpId.value }",
6565
"type": "${ BMinpType.value }",
6666
"images": [ ${ BMinpImages.value } ],

0 commit comments

Comments
 (0)