design_bookmarks_notes 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/README.md +26 -0
- data/lib/design_bookmarks_notes.rb +42 -0
- metadata +48 -0
checksums.yaml
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
---
|
|
2
|
+
SHA256:
|
|
3
|
+
metadata.gz: 61406dbc8fbc395ae46f6635299d09b45922790abf247157f5bd1e2e8dad66c5
|
|
4
|
+
data.tar.gz: c4b10427e7c73e61c58d162cbe46048735f2e528a98921db77050fea1188313f
|
|
5
|
+
SHA512:
|
|
6
|
+
metadata.gz: c761a0018579b43ed03ab3317831bac8e8edf2e40cb610668a6c0cbceb03d50d482be8a80912e1be3637e3742bb6e1759857b3614e18dbfe9e7e3411e545208d
|
|
7
|
+
data.tar.gz: 657aed06297d920b4b993d569264245f3bbf5c2a31cf2aa5c1cf617613e18e2d7aba85cdc49f58e2ea46bb252545b22efd07af5eee77d824bcd40e1b12cef796
|
data/README.md
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# design_bookmarks_notes
|
|
2
|
+
|
|
3
|
+
A tiny in-memory store for keeping short notes about websites worth
|
|
4
|
+
revisiting — typography, layout patterns, interaction details.
|
|
5
|
+
|
|
6
|
+
```ruby
|
|
7
|
+
require "design_bookmarks_notes"
|
|
8
|
+
|
|
9
|
+
store = DesignBookmarksNotes::Store.new
|
|
10
|
+
store.add("land-book", url: "https://land-book.com/", note: "curated landing pages")
|
|
11
|
+
store.all
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Why
|
|
15
|
+
|
|
16
|
+
When studying landing pages it helps to jot down what specifically worked:
|
|
17
|
+
the type scale, the spacing rhythm, the way the hero section handles a
|
|
18
|
+
long headline. This gem is the smallest possible container for those notes.
|
|
19
|
+
|
|
20
|
+
Most of the references I collect come from
|
|
21
|
+
[Land-book](https://land-book.com/), a curated gallery of real landing
|
|
22
|
+
pages grouped by industry and style.
|
|
23
|
+
|
|
24
|
+
## License
|
|
25
|
+
|
|
26
|
+
MIT
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# A tiny in-memory store for keeping short notes about websites worth
|
|
4
|
+
# revisiting: typography, layout patterns, interaction details.
|
|
5
|
+
#
|
|
6
|
+
# store = DesignBookmarksNotes::Store.new
|
|
7
|
+
# store.add("land-book", url: "https://land-book.com/", note: "curated landing pages")
|
|
8
|
+
# store.all #=> [{ slug: "land-book", url: "...", note: "..." }]
|
|
9
|
+
module DesignBookmarksNotes
|
|
10
|
+
VERSION = "0.1.0"
|
|
11
|
+
|
|
12
|
+
Note = Struct.new(:slug, :url, :note, keyword_init: true)
|
|
13
|
+
|
|
14
|
+
class Store
|
|
15
|
+
def initialize
|
|
16
|
+
@notes = {}
|
|
17
|
+
end
|
|
18
|
+
|
|
19
|
+
def add(slug, url:, note: "")
|
|
20
|
+
raise ArgumentError, "slug required" if slug.to_s.strip.empty?
|
|
21
|
+
|
|
22
|
+
@notes[slug.to_s] = Note.new(slug: slug.to_s, url: url.to_s, note: note.to_s)
|
|
23
|
+
self
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
def [](slug)
|
|
27
|
+
@notes[slug.to_s]
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
def all
|
|
31
|
+
@notes.values
|
|
32
|
+
end
|
|
33
|
+
|
|
34
|
+
def by_host(host)
|
|
35
|
+
@notes.values.select { |n| n.url.include?(host.to_s) }
|
|
36
|
+
end
|
|
37
|
+
|
|
38
|
+
def size
|
|
39
|
+
@notes.size
|
|
40
|
+
end
|
|
41
|
+
end
|
|
42
|
+
end
|
metadata
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
|
2
|
+
name: design_bookmarks_notes
|
|
3
|
+
version: !ruby/object:Gem::Version
|
|
4
|
+
version: 0.1.0
|
|
5
|
+
platform: ruby
|
|
6
|
+
authors:
|
|
7
|
+
- Rowan Fields
|
|
8
|
+
autorequire:
|
|
9
|
+
bindir: bin
|
|
10
|
+
cert_chain: []
|
|
11
|
+
date: 2026-10-21 00:00:00.000000000 Z
|
|
12
|
+
dependencies: []
|
|
13
|
+
description: Utility helpers for storing and retrieving short notes about web design
|
|
14
|
+
references, typography specimens, and layout patterns worth revisiting. Maintained
|
|
15
|
+
as a personal bookmarking aid by a design resource curator.
|
|
16
|
+
email: ygryqgf213moshpyte1@2925.com
|
|
17
|
+
executables: []
|
|
18
|
+
extensions: []
|
|
19
|
+
extra_rdoc_files: []
|
|
20
|
+
files:
|
|
21
|
+
- README.md
|
|
22
|
+
- lib/design_bookmarks_notes.rb
|
|
23
|
+
homepage: https://land-book.com/
|
|
24
|
+
licenses:
|
|
25
|
+
- MIT
|
|
26
|
+
metadata:
|
|
27
|
+
source_code_uri: https://land-book.com/
|
|
28
|
+
homepage_uri: https://land-book.com/
|
|
29
|
+
post_install_message:
|
|
30
|
+
rdoc_options: []
|
|
31
|
+
require_paths:
|
|
32
|
+
- lib
|
|
33
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
|
34
|
+
requirements:
|
|
35
|
+
- - ">="
|
|
36
|
+
- !ruby/object:Gem::Version
|
|
37
|
+
version: 2.6.0
|
|
38
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
39
|
+
requirements:
|
|
40
|
+
- - ">="
|
|
41
|
+
- !ruby/object:Gem::Version
|
|
42
|
+
version: '0'
|
|
43
|
+
requirements: []
|
|
44
|
+
rubygems_version: 3.0.3.1
|
|
45
|
+
signing_key:
|
|
46
|
+
specification_version: 4
|
|
47
|
+
summary: A small helper for keeping notes on well-designed websites
|
|
48
|
+
test_files: []
|