administrate-field-hyperlink 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/.gitignore +9 -0
- data/.idea/.rakeTasks +7 -0
- data/.idea/administrate-field-hyperlink.iml +57 -0
- data/.idea/misc.xml +7 -0
- data/.idea/modules.xml +8 -0
- data/.idea/vcs.xml +6 -0
- data/.idea/workspace.xml +463 -0
- data/CHANGELOG.md +18 -0
- data/Gemfile +3 -0
- data/LICENSE +21 -0
- data/README.md +86 -0
- data/Rakefile +10 -0
- data/administrate-field-hyperlink.gemspec +41 -0
- data/app/views/fields/hyperlink/_form.html.erb +24 -0
- data/app/views/fields/hyperlink/_index.html.erb +19 -0
- data/app/views/fields/hyperlink/_show.html.erb +19 -0
- data/lib/administrate/field/hyperlink.rb +21 -0
- data/lib/administrate/field/hyperlink/version.rb +9 -0
- metadata +127 -0
checksums.yaml
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
---
|
|
2
|
+
SHA256:
|
|
3
|
+
metadata.gz: 0e3bcbc9daf9d05b76cd656628cc072f1459d5bd6f02d3974b5f32db178d1abe
|
|
4
|
+
data.tar.gz: 46693b78a2978622536993f387e43165e2bbc885bd6368c4d31b662c99dcd00a
|
|
5
|
+
SHA512:
|
|
6
|
+
metadata.gz: 67d237b4bfadc72b76cfc6131d602d29a48d4242a672416789bd6df22342baec6882443ecf29493288cfa869d12306e5756ca35a35f20f1e71d9b006def900de
|
|
7
|
+
data.tar.gz: ff278081b8fe5f777ce11a2d59d6f8d7bacffb042ebc71f6e1c0c111fa30683b30a4edf095d4e5d7c2bb49faa5988fd1bb06c72353fb07b5e4638ef5f6ea138b
|
data/.gitignore
ADDED
data/.idea/.rakeTasks
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<Settings><!--This file was automatically generated by Ruby plugin.
|
|
3
|
+
You are allowed to:
|
|
4
|
+
1. Remove rake task
|
|
5
|
+
2. Add existing rake tasks
|
|
6
|
+
To add existing rake tasks automatically delete this file and reload the project.
|
|
7
|
+
--><RakeGroup description="" fullCmd="" taksId="rake" /></Settings>
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<module type="RUBY_MODULE" version="4">
|
|
3
|
+
<component name="ModuleRunConfigurationManager">
|
|
4
|
+
<shared />
|
|
5
|
+
</component>
|
|
6
|
+
<component name="NewModuleRootManager">
|
|
7
|
+
<content url="file://$MODULE_DIR$" />
|
|
8
|
+
<orderEntry type="inheritedJdk" />
|
|
9
|
+
<orderEntry type="sourceFolder" forTests="false" />
|
|
10
|
+
<orderEntry type="library" scope="PROVIDED" name="actionpack (v5.2.2.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
11
|
+
<orderEntry type="library" scope="PROVIDED" name="actionview (v5.2.2.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
12
|
+
<orderEntry type="library" scope="PROVIDED" name="activemodel (v5.2.2.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
13
|
+
<orderEntry type="library" scope="PROVIDED" name="activerecord (v5.2.2.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
14
|
+
<orderEntry type="library" scope="PROVIDED" name="activesupport (v5.2.2.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
15
|
+
<orderEntry type="library" scope="PROVIDED" name="administrate (v0.11.0, ruby-2.5.3-p105) [gem]" level="application" />
|
|
16
|
+
<orderEntry type="library" scope="PROVIDED" name="arel (v9.0.0, ruby-2.5.3-p105) [gem]" level="application" />
|
|
17
|
+
<orderEntry type="library" scope="PROVIDED" name="autoprefixer-rails (v9.5.0, ruby-2.5.3-p105) [gem]" level="application" />
|
|
18
|
+
<orderEntry type="library" scope="PROVIDED" name="builder (v3.2.3, ruby-2.5.3-p105) [gem]" level="application" />
|
|
19
|
+
<orderEntry type="library" scope="PROVIDED" name="bundler (v2.0.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
20
|
+
<orderEntry type="library" scope="PROVIDED" name="concurrent-ruby (v1.1.5, ruby-2.5.3-p105) [gem]" level="application" />
|
|
21
|
+
<orderEntry type="library" scope="PROVIDED" name="crass (v1.0.4, ruby-2.5.3-p105) [gem]" level="application" />
|
|
22
|
+
<orderEntry type="library" scope="PROVIDED" name="datetime_picker_rails (v0.0.7, ruby-2.5.3-p105) [gem]" level="application" />
|
|
23
|
+
<orderEntry type="library" scope="PROVIDED" name="erubi (v1.8.0, ruby-2.5.3-p105) [gem]" level="application" />
|
|
24
|
+
<orderEntry type="library" scope="PROVIDED" name="execjs (v2.7.0, ruby-2.5.3-p105) [gem]" level="application" />
|
|
25
|
+
<orderEntry type="library" scope="PROVIDED" name="ffi (v1.10.0, ruby-2.5.3-p105) [gem]" level="application" />
|
|
26
|
+
<orderEntry type="library" scope="PROVIDED" name="i18n (v1.6.0, ruby-2.5.3-p105) [gem]" level="application" />
|
|
27
|
+
<orderEntry type="library" scope="PROVIDED" name="jquery-rails (v4.3.3, ruby-2.5.3-p105) [gem]" level="application" />
|
|
28
|
+
<orderEntry type="library" scope="PROVIDED" name="kaminari (v1.1.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
29
|
+
<orderEntry type="library" scope="PROVIDED" name="kaminari-actionview (v1.1.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
30
|
+
<orderEntry type="library" scope="PROVIDED" name="kaminari-activerecord (v1.1.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
31
|
+
<orderEntry type="library" scope="PROVIDED" name="kaminari-core (v1.1.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
32
|
+
<orderEntry type="library" scope="PROVIDED" name="loofah (v2.2.3, ruby-2.5.3-p105) [gem]" level="application" />
|
|
33
|
+
<orderEntry type="library" scope="PROVIDED" name="method_source (v0.9.2, ruby-2.5.3-p105) [gem]" level="application" />
|
|
34
|
+
<orderEntry type="library" scope="PROVIDED" name="mini_portile2 (v2.4.0, ruby-2.5.3-p105) [gem]" level="application" />
|
|
35
|
+
<orderEntry type="library" scope="PROVIDED" name="minitest (v5.11.3, ruby-2.5.3-p105) [gem]" level="application" />
|
|
36
|
+
<orderEntry type="library" scope="PROVIDED" name="momentjs-rails (v2.20.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
37
|
+
<orderEntry type="library" scope="PROVIDED" name="nokogiri (v1.10.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
38
|
+
<orderEntry type="library" scope="PROVIDED" name="rack (v2.0.6, ruby-2.5.3-p105) [gem]" level="application" />
|
|
39
|
+
<orderEntry type="library" scope="PROVIDED" name="rack-test (v1.1.0, ruby-2.5.3-p105) [gem]" level="application" />
|
|
40
|
+
<orderEntry type="library" scope="PROVIDED" name="rails-dom-testing (v2.0.3, ruby-2.5.3-p105) [gem]" level="application" />
|
|
41
|
+
<orderEntry type="library" scope="PROVIDED" name="rails-html-sanitizer (v1.0.4, ruby-2.5.3-p105) [gem]" level="application" />
|
|
42
|
+
<orderEntry type="library" scope="PROVIDED" name="railties (v5.2.2.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
43
|
+
<orderEntry type="library" scope="PROVIDED" name="rake (v10.5.0, ruby-2.5.3-p105) [gem]" level="application" />
|
|
44
|
+
<orderEntry type="library" scope="PROVIDED" name="rb-fsevent (v0.10.3, ruby-2.5.3-p105) [gem]" level="application" />
|
|
45
|
+
<orderEntry type="library" scope="PROVIDED" name="rb-inotify (v0.10.0, ruby-2.5.3-p105) [gem]" level="application" />
|
|
46
|
+
<orderEntry type="library" scope="PROVIDED" name="sass (v3.7.3, ruby-2.5.3-p105) [gem]" level="application" />
|
|
47
|
+
<orderEntry type="library" scope="PROVIDED" name="sass-listen (v4.0.0, ruby-2.5.3-p105) [gem]" level="application" />
|
|
48
|
+
<orderEntry type="library" scope="PROVIDED" name="sass-rails (v5.0.7, ruby-2.5.3-p105) [gem]" level="application" />
|
|
49
|
+
<orderEntry type="library" scope="PROVIDED" name="selectize-rails (v0.12.6, ruby-2.5.3-p105) [gem]" level="application" />
|
|
50
|
+
<orderEntry type="library" scope="PROVIDED" name="sprockets (v3.7.2, ruby-2.5.3-p105) [gem]" level="application" />
|
|
51
|
+
<orderEntry type="library" scope="PROVIDED" name="sprockets-rails (v3.2.1, ruby-2.5.3-p105) [gem]" level="application" />
|
|
52
|
+
<orderEntry type="library" scope="PROVIDED" name="thor (v0.20.3, ruby-2.5.3-p105) [gem]" level="application" />
|
|
53
|
+
<orderEntry type="library" scope="PROVIDED" name="thread_safe (v0.3.6, ruby-2.5.3-p105) [gem]" level="application" />
|
|
54
|
+
<orderEntry type="library" scope="PROVIDED" name="tilt (v2.0.9, ruby-2.5.3-p105) [gem]" level="application" />
|
|
55
|
+
<orderEntry type="library" scope="PROVIDED" name="tzinfo (v1.2.5, ruby-2.5.3-p105) [gem]" level="application" />
|
|
56
|
+
</component>
|
|
57
|
+
</module>
|
data/.idea/misc.xml
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<project version="4">
|
|
3
|
+
<component name="JavaScriptSettings">
|
|
4
|
+
<option name="languageLevel" value="ES6" />
|
|
5
|
+
</component>
|
|
6
|
+
<component name="ProjectRootManager" version="2" project-jdk-name="ruby-2.5.3-p105" project-jdk-type="RUBY_SDK" />
|
|
7
|
+
</project>
|
data/.idea/modules.xml
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<project version="4">
|
|
3
|
+
<component name="ProjectModuleManager">
|
|
4
|
+
<modules>
|
|
5
|
+
<module fileurl="file://$PROJECT_DIR$/.idea/administrate-field-hyperlink.iml" filepath="$PROJECT_DIR$/.idea/administrate-field-hyperlink.iml" />
|
|
6
|
+
</modules>
|
|
7
|
+
</component>
|
|
8
|
+
</project>
|
data/.idea/vcs.xml
ADDED
data/.idea/workspace.xml
ADDED
|
@@ -0,0 +1,463 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<project version="4">
|
|
3
|
+
<component name="ChangeListManager">
|
|
4
|
+
<list default="true" id="6725c096-4ab6-4364-8920-1d9f58c0b869" name="Default Changelist" comment="">
|
|
5
|
+
<change beforePath="$PROJECT_DIR$/.idea/administrate-field-hyperlink.iml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/administrate-field-hyperlink.iml" afterDir="false" />
|
|
6
|
+
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
|
7
|
+
<change beforePath="$PROJECT_DIR$/administrate-field-hyperlink.gemspec" beforeDir="false" afterPath="$PROJECT_DIR$/administrate-field-hyperlink.gemspec" afterDir="false" />
|
|
8
|
+
</list>
|
|
9
|
+
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
|
|
10
|
+
<option name="SHOW_DIALOG" value="false" />
|
|
11
|
+
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
|
12
|
+
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
|
13
|
+
<option name="LAST_RESOLUTION" value="IGNORE" />
|
|
14
|
+
</component>
|
|
15
|
+
<component name="FileEditorManager">
|
|
16
|
+
<leaf>
|
|
17
|
+
<file pinned="false" current-in-tab="false">
|
|
18
|
+
<entry file="file://$PROJECT_DIR$/README.md">
|
|
19
|
+
<provider selected="true" editor-type-id="split-provider[text-editor;markdown-preview-editor]">
|
|
20
|
+
<state split_layout="SPLIT">
|
|
21
|
+
<first_editor relative-caret-position="280">
|
|
22
|
+
<caret line="68" column="147" selection-start-line="68" selection-start-column="147" selection-end-line="68" selection-end-column="147" />
|
|
23
|
+
</first_editor>
|
|
24
|
+
<second_editor />
|
|
25
|
+
</state>
|
|
26
|
+
</provider>
|
|
27
|
+
</entry>
|
|
28
|
+
</file>
|
|
29
|
+
<file pinned="false" current-in-tab="false">
|
|
30
|
+
<entry file="file://$PROJECT_DIR$/administrate-field-hyperlink.gemspec">
|
|
31
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
32
|
+
<state relative-caret-position="442">
|
|
33
|
+
<caret line="35" lean-forward="true" selection-start-line="35" selection-end-line="35" />
|
|
34
|
+
</state>
|
|
35
|
+
</provider>
|
|
36
|
+
</entry>
|
|
37
|
+
</file>
|
|
38
|
+
<file pinned="false" current-in-tab="true">
|
|
39
|
+
<entry file="file://$PROJECT_DIR$/Gemfile.lock">
|
|
40
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
41
|
+
<state relative-caret-position="85">
|
|
42
|
+
<caret line="5" column="3" lean-forward="true" selection-start-line="5" selection-start-column="3" selection-end-line="5" selection-end-column="3" />
|
|
43
|
+
</state>
|
|
44
|
+
</provider>
|
|
45
|
+
</entry>
|
|
46
|
+
</file>
|
|
47
|
+
<file pinned="false" current-in-tab="false">
|
|
48
|
+
<entry file="file://$PROJECT_DIR$/Rakefile">
|
|
49
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
50
|
+
<state relative-caret-position="170">
|
|
51
|
+
<caret line="10" selection-start-line="10" selection-end-line="10" />
|
|
52
|
+
</state>
|
|
53
|
+
</provider>
|
|
54
|
+
</entry>
|
|
55
|
+
</file>
|
|
56
|
+
<file pinned="false" current-in-tab="false">
|
|
57
|
+
<entry file="file://$PROJECT_DIR$/lib/administrate/field/hyperlink/version.rb">
|
|
58
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
59
|
+
<state relative-caret-position="68">
|
|
60
|
+
<caret line="4" column="49" selection-start-line="4" selection-start-column="4" selection-end-line="4" selection-end-column="49" />
|
|
61
|
+
</state>
|
|
62
|
+
</provider>
|
|
63
|
+
</entry>
|
|
64
|
+
</file>
|
|
65
|
+
<file pinned="false" current-in-tab="false">
|
|
66
|
+
<entry file="file://$PROJECT_DIR$/test/lib/administrate/field/hyperlink_test.rb">
|
|
67
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
68
|
+
<state relative-caret-position="340">
|
|
69
|
+
<caret line="26" column="21" selection-start-line="26" selection-start-column="21" selection-end-line="26" selection-end-column="21" />
|
|
70
|
+
</state>
|
|
71
|
+
</provider>
|
|
72
|
+
</entry>
|
|
73
|
+
</file>
|
|
74
|
+
<file pinned="false" current-in-tab="false">
|
|
75
|
+
<entry file="file://$PROJECT_DIR$/lib/administrate/field/hyperlink.rb">
|
|
76
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
77
|
+
<state relative-caret-position="272">
|
|
78
|
+
<caret line="16" column="33" selection-start-line="16" selection-start-column="11" selection-end-line="16" selection-end-column="33" />
|
|
79
|
+
</state>
|
|
80
|
+
</provider>
|
|
81
|
+
</entry>
|
|
82
|
+
</file>
|
|
83
|
+
<file pinned="false" current-in-tab="false">
|
|
84
|
+
<entry file="file://$PROJECT_DIR$/test/test_helper.rb">
|
|
85
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
86
|
+
<state relative-caret-position="34">
|
|
87
|
+
<caret line="2" column="38" selection-start-line="2" selection-start-column="38" selection-end-line="2" selection-end-column="38" />
|
|
88
|
+
</state>
|
|
89
|
+
</provider>
|
|
90
|
+
</entry>
|
|
91
|
+
</file>
|
|
92
|
+
</leaf>
|
|
93
|
+
</component>
|
|
94
|
+
<component name="FindInProjectRecents">
|
|
95
|
+
<findStrings>
|
|
96
|
+
<find>base_controller</find>
|
|
97
|
+
</findStrings>
|
|
98
|
+
<replaceStrings>
|
|
99
|
+
<replace>field-hyperlink</replace>
|
|
100
|
+
</replaceStrings>
|
|
101
|
+
</component>
|
|
102
|
+
<component name="Git.Settings">
|
|
103
|
+
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
|
|
104
|
+
</component>
|
|
105
|
+
<component name="IdeDocumentHistory">
|
|
106
|
+
<option name="CHANGED_PATHS">
|
|
107
|
+
<list>
|
|
108
|
+
<option value="$PROJECT_DIR$/administrate-field-image.gemspec" />
|
|
109
|
+
<option value="$PROJECT_DIR$/lib/administrate/field/hyperlink/version.rb" />
|
|
110
|
+
<option value="$PROJECT_DIR$/test/test_helper.rb" />
|
|
111
|
+
<option value="$PROJECT_DIR$/lib/administrate/field/hyperlink.rb" />
|
|
112
|
+
<option value="$PROJECT_DIR$/app/views/fields/hyperlink/_form.html.erb" />
|
|
113
|
+
<option value="$PROJECT_DIR$/app/views/fields/hyperlink/_index.html.erb" />
|
|
114
|
+
<option value="$PROJECT_DIR$/app/views/fields/hyperlink/_show.html.erb" />
|
|
115
|
+
<option value="$PROJECT_DIR$/Rakefile" />
|
|
116
|
+
<option value="$PROJECT_DIR$/test/lib/administrate/field/hyperlink_test.rb" />
|
|
117
|
+
<option value="$PROJECT_DIR$/README.md" />
|
|
118
|
+
<option value="$PROJECT_DIR$/../administrate-base_controller/administrate-base_controller.gemspec" />
|
|
119
|
+
<option value="$PROJECT_DIR$/administrate-field-hyperlink.gemspec" />
|
|
120
|
+
</list>
|
|
121
|
+
</option>
|
|
122
|
+
</component>
|
|
123
|
+
<component name="ProjectConfigurationFiles">
|
|
124
|
+
<option name="files">
|
|
125
|
+
<list>
|
|
126
|
+
<option value="$PROJECT_DIR$/.idea/administrate-field-hyperlink.iml" />
|
|
127
|
+
<option value="$PROJECT_DIR$/.idea/misc.xml" />
|
|
128
|
+
<option value="$PROJECT_DIR$/.idea/vcs.xml" />
|
|
129
|
+
<option value="$PROJECT_DIR$/.idea/modules.xml" />
|
|
130
|
+
</list>
|
|
131
|
+
</option>
|
|
132
|
+
</component>
|
|
133
|
+
<component name="ProjectFrameBounds" extendedState="6">
|
|
134
|
+
<option name="x" value="-14" />
|
|
135
|
+
<option name="y" value="-14" />
|
|
136
|
+
<option name="width" value="3868" />
|
|
137
|
+
<option name="height" value="2120" />
|
|
138
|
+
</component>
|
|
139
|
+
<component name="ProjectLevelVcsManager" settingsEditedManually="true" />
|
|
140
|
+
<component name="ProjectView">
|
|
141
|
+
<navigator proportions="" version="1">
|
|
142
|
+
<foldersAlwaysOnTop value="true" />
|
|
143
|
+
</navigator>
|
|
144
|
+
<panes>
|
|
145
|
+
<pane id="ProjectPane">
|
|
146
|
+
<subPane>
|
|
147
|
+
<expand>
|
|
148
|
+
<path>
|
|
149
|
+
<item name="administrate-field-hyperlink" type="b2602c69:ProjectViewProjectNode" />
|
|
150
|
+
<item name="administrate-field-hyperlink" type="462c0819:PsiDirectoryNode" />
|
|
151
|
+
</path>
|
|
152
|
+
<path>
|
|
153
|
+
<item name="administrate-field-hyperlink" type="b2602c69:ProjectViewProjectNode" />
|
|
154
|
+
<item name="administrate-field-hyperlink" type="462c0819:PsiDirectoryNode" />
|
|
155
|
+
<item name="app" type="462c0819:PsiDirectoryNode" />
|
|
156
|
+
</path>
|
|
157
|
+
<path>
|
|
158
|
+
<item name="administrate-field-hyperlink" type="b2602c69:ProjectViewProjectNode" />
|
|
159
|
+
<item name="administrate-field-hyperlink" type="462c0819:PsiDirectoryNode" />
|
|
160
|
+
<item name="app" type="462c0819:PsiDirectoryNode" />
|
|
161
|
+
<item name="views" type="462c0819:PsiDirectoryNode" />
|
|
162
|
+
</path>
|
|
163
|
+
<path>
|
|
164
|
+
<item name="administrate-field-hyperlink" type="b2602c69:ProjectViewProjectNode" />
|
|
165
|
+
<item name="administrate-field-hyperlink" type="462c0819:PsiDirectoryNode" />
|
|
166
|
+
<item name="app" type="462c0819:PsiDirectoryNode" />
|
|
167
|
+
<item name="views" type="462c0819:PsiDirectoryNode" />
|
|
168
|
+
<item name="fields" type="462c0819:PsiDirectoryNode" />
|
|
169
|
+
</path>
|
|
170
|
+
<path>
|
|
171
|
+
<item name="administrate-field-hyperlink" type="b2602c69:ProjectViewProjectNode" />
|
|
172
|
+
<item name="administrate-field-hyperlink" type="462c0819:PsiDirectoryNode" />
|
|
173
|
+
<item name="app" type="462c0819:PsiDirectoryNode" />
|
|
174
|
+
<item name="views" type="462c0819:PsiDirectoryNode" />
|
|
175
|
+
<item name="fields" type="462c0819:PsiDirectoryNode" />
|
|
176
|
+
<item name="hyperlink" type="462c0819:PsiDirectoryNode" />
|
|
177
|
+
</path>
|
|
178
|
+
<path>
|
|
179
|
+
<item name="administrate-field-hyperlink" type="b2602c69:ProjectViewProjectNode" />
|
|
180
|
+
<item name="administrate-field-hyperlink" type="462c0819:PsiDirectoryNode" />
|
|
181
|
+
<item name="lib" type="462c0819:PsiDirectoryNode" />
|
|
182
|
+
</path>
|
|
183
|
+
<path>
|
|
184
|
+
<item name="administrate-field-hyperlink" type="b2602c69:ProjectViewProjectNode" />
|
|
185
|
+
<item name="administrate-field-hyperlink" type="462c0819:PsiDirectoryNode" />
|
|
186
|
+
<item name="lib" type="462c0819:PsiDirectoryNode" />
|
|
187
|
+
<item name="administrate" type="462c0819:PsiDirectoryNode" />
|
|
188
|
+
</path>
|
|
189
|
+
<path>
|
|
190
|
+
<item name="administrate-field-hyperlink" type="b2602c69:ProjectViewProjectNode" />
|
|
191
|
+
<item name="administrate-field-hyperlink" type="462c0819:PsiDirectoryNode" />
|
|
192
|
+
<item name="lib" type="462c0819:PsiDirectoryNode" />
|
|
193
|
+
<item name="administrate" type="462c0819:PsiDirectoryNode" />
|
|
194
|
+
<item name="field" type="462c0819:PsiDirectoryNode" />
|
|
195
|
+
</path>
|
|
196
|
+
<path>
|
|
197
|
+
<item name="administrate-field-hyperlink" type="b2602c69:ProjectViewProjectNode" />
|
|
198
|
+
<item name="administrate-field-hyperlink" type="462c0819:PsiDirectoryNode" />
|
|
199
|
+
<item name="test" type="462c0819:PsiDirectoryNode" />
|
|
200
|
+
</path>
|
|
201
|
+
<path>
|
|
202
|
+
<item name="administrate-field-hyperlink" type="b2602c69:ProjectViewProjectNode" />
|
|
203
|
+
<item name="administrate-field-hyperlink" type="462c0819:PsiDirectoryNode" />
|
|
204
|
+
<item name="test" type="462c0819:PsiDirectoryNode" />
|
|
205
|
+
<item name="lib" type="462c0819:PsiDirectoryNode" />
|
|
206
|
+
</path>
|
|
207
|
+
<path>
|
|
208
|
+
<item name="administrate-field-hyperlink" type="b2602c69:ProjectViewProjectNode" />
|
|
209
|
+
<item name="administrate-field-hyperlink" type="462c0819:PsiDirectoryNode" />
|
|
210
|
+
<item name="test" type="462c0819:PsiDirectoryNode" />
|
|
211
|
+
<item name="lib" type="462c0819:PsiDirectoryNode" />
|
|
212
|
+
<item name="administrate" type="462c0819:PsiDirectoryNode" />
|
|
213
|
+
</path>
|
|
214
|
+
<path>
|
|
215
|
+
<item name="administrate-field-hyperlink" type="b2602c69:ProjectViewProjectNode" />
|
|
216
|
+
<item name="administrate-field-hyperlink" type="462c0819:PsiDirectoryNode" />
|
|
217
|
+
<item name="test" type="462c0819:PsiDirectoryNode" />
|
|
218
|
+
<item name="lib" type="462c0819:PsiDirectoryNode" />
|
|
219
|
+
<item name="administrate" type="462c0819:PsiDirectoryNode" />
|
|
220
|
+
<item name="field" type="462c0819:PsiDirectoryNode" />
|
|
221
|
+
</path>
|
|
222
|
+
</expand>
|
|
223
|
+
<select />
|
|
224
|
+
</subPane>
|
|
225
|
+
</pane>
|
|
226
|
+
<pane id="Scope" />
|
|
227
|
+
</panes>
|
|
228
|
+
</component>
|
|
229
|
+
<component name="PropertiesComponent">
|
|
230
|
+
<property name="WebServerToolWindowFactoryState" value="false" />
|
|
231
|
+
<property name="last_opened_file_path" value="$PROJECT_DIR$" />
|
|
232
|
+
<property name="nodejs_interpreter_path.stuck_in_default_project" value="undefined stuck path" />
|
|
233
|
+
<property name="nodejs_npm_path_reset_for_default_project" value="true" />
|
|
234
|
+
<property name="settings.editor.selected.configurable" value="preferences.lookFeel" />
|
|
235
|
+
</component>
|
|
236
|
+
<component name="RecentsManager">
|
|
237
|
+
<key name="CopyFile.RECENT_KEYS">
|
|
238
|
+
<recent name="C:\Users\Derk-Jan\Documents\Github\administrate-field-hyperlink\test" />
|
|
239
|
+
</key>
|
|
240
|
+
</component>
|
|
241
|
+
<component name="RunDashboard">
|
|
242
|
+
<option name="ruleStates">
|
|
243
|
+
<list>
|
|
244
|
+
<RuleState>
|
|
245
|
+
<option name="name" value="ConfigurationTypeDashboardGroupingRule" />
|
|
246
|
+
</RuleState>
|
|
247
|
+
<RuleState>
|
|
248
|
+
<option name="name" value="StatusDashboardGroupingRule" />
|
|
249
|
+
</RuleState>
|
|
250
|
+
</list>
|
|
251
|
+
</option>
|
|
252
|
+
</component>
|
|
253
|
+
<component name="RunManager">
|
|
254
|
+
<configuration name="Unnamed" type="RakeRunConfigurationType" factoryName="Rake" nameIsGenerated="true">
|
|
255
|
+
<module name="administrate-field-hyperlink" />
|
|
256
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RUBY_ARGS" VALUE="" />
|
|
257
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="WORK DIR" VALUE="$MODULE_DIR$" />
|
|
258
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="SHOULD_USE_SDK" VALUE="false" />
|
|
259
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="ALTERN_SDK_NAME" VALUE="" />
|
|
260
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="myPassParentEnvs" VALUE="true" />
|
|
261
|
+
<EXTENSION ID="BundlerRunConfigurationExtension" bundleExecEnabled="true" />
|
|
262
|
+
<EXTENSION ID="JRubyRunConfigurationExtension" NailgunExecEnabled="false" />
|
|
263
|
+
<EXTENSION ID="RubyCoverageRunConfigurationExtension" track_test_folders="true" runner="rcov" />
|
|
264
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RAKE_TASK_NAME" VALUE="test" />
|
|
265
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RAKE_TASK_ARGS" VALUE="" />
|
|
266
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RAKE_TASK_ATTACHED_TEST_FRAMEWORKS" VALUE=":test_unit " />
|
|
267
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RAKE_TASK_OPTION_TRACE" VALUE="false" />
|
|
268
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RAKE_TASK_OPTION_DRYRUN" VALUE="false" />
|
|
269
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RAKE_TASK_OPTION_PREREQS" VALUE="false" />
|
|
270
|
+
<method v="2" />
|
|
271
|
+
</configuration>
|
|
272
|
+
<configuration default="true" type="RakeRunConfigurationType" factoryName="Rake">
|
|
273
|
+
<module name="administrate-field-hyperlink" />
|
|
274
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RUBY_ARGS" VALUE="" />
|
|
275
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="WORK DIR" VALUE="" />
|
|
276
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="SHOULD_USE_SDK" VALUE="false" />
|
|
277
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="ALTERN_SDK_NAME" VALUE="" />
|
|
278
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="myPassParentEnvs" VALUE="true" />
|
|
279
|
+
<EXTENSION ID="BundlerRunConfigurationExtension" bundleExecEnabled="true" />
|
|
280
|
+
<EXTENSION ID="JRubyRunConfigurationExtension" NailgunExecEnabled="false" />
|
|
281
|
+
<EXTENSION ID="RubyCoverageRunConfigurationExtension" track_test_folders="true" runner="rcov" />
|
|
282
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RAKE_TASK_NAME" VALUE="test" />
|
|
283
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RAKE_TASK_ARGS" VALUE="" />
|
|
284
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RAKE_TASK_ATTACHED_TEST_FRAMEWORKS" VALUE=":test_unit " />
|
|
285
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RAKE_TASK_OPTION_TRACE" VALUE="false" />
|
|
286
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RAKE_TASK_OPTION_DRYRUN" VALUE="false" />
|
|
287
|
+
<RAKE_RUN_CONFIG_SETTINGS_ID NAME="RAKE_TASK_OPTION_PREREQS" VALUE="false" />
|
|
288
|
+
<method v="2" />
|
|
289
|
+
</configuration>
|
|
290
|
+
</component>
|
|
291
|
+
<component name="SpringUtil" SPRING_PRE_LOADER_OPTION="true" />
|
|
292
|
+
<component name="SvnConfiguration">
|
|
293
|
+
<configuration />
|
|
294
|
+
</component>
|
|
295
|
+
<component name="TaskManager">
|
|
296
|
+
<task active="true" id="Default" summary="Default task">
|
|
297
|
+
<changelist id="6725c096-4ab6-4364-8920-1d9f58c0b869" name="Default Changelist" comment="" />
|
|
298
|
+
<created>1552648579226</created>
|
|
299
|
+
<option name="number" value="Default" />
|
|
300
|
+
<option name="presentableId" value="Default" />
|
|
301
|
+
<updated>1552648579226</updated>
|
|
302
|
+
<workItem from="1552648580349" duration="1641000" />
|
|
303
|
+
</task>
|
|
304
|
+
<servers />
|
|
305
|
+
</component>
|
|
306
|
+
<component name="TestHistory">
|
|
307
|
+
<history-entry file="Unnamed - 2019.03.15 at 12h 33m 48s.xml">
|
|
308
|
+
<configuration name="Unnamed" configurationId="RakeRunConfigurationType" />
|
|
309
|
+
</history-entry>
|
|
310
|
+
<history-entry file="Unnamed - 2019.03.15 at 12h 34m 09s.xml">
|
|
311
|
+
<configuration name="Unnamed" configurationId="RakeRunConfigurationType" />
|
|
312
|
+
</history-entry>
|
|
313
|
+
<history-entry file="Unnamed - 2019.03.15 at 12h 34m 48s.xml">
|
|
314
|
+
<configuration name="Unnamed" configurationId="RakeRunConfigurationType" />
|
|
315
|
+
</history-entry>
|
|
316
|
+
<history-entry file="Unnamed - 2019.03.15 at 12h 35m 06s.xml">
|
|
317
|
+
<configuration name="Unnamed" configurationId="RakeRunConfigurationType" />
|
|
318
|
+
</history-entry>
|
|
319
|
+
</component>
|
|
320
|
+
<component name="TimeTrackingManager">
|
|
321
|
+
<option name="totallyTimeSpent" value="1641000" />
|
|
322
|
+
</component>
|
|
323
|
+
<component name="TodoView">
|
|
324
|
+
<todo-panel id="selected-file">
|
|
325
|
+
<is-autoscroll-to-source value="true" />
|
|
326
|
+
</todo-panel>
|
|
327
|
+
<todo-panel id="all">
|
|
328
|
+
<are-packages-shown value="true" />
|
|
329
|
+
<is-autoscroll-to-source value="true" />
|
|
330
|
+
</todo-panel>
|
|
331
|
+
</component>
|
|
332
|
+
<component name="ToolWindowManager">
|
|
333
|
+
<frame x="-6" y="-6" width="1719" height="942" extended-state="6" />
|
|
334
|
+
<editor active="true" />
|
|
335
|
+
<layout>
|
|
336
|
+
<window_info id="Favorites" side_tool="true" />
|
|
337
|
+
<window_info active="true" content_ui="combo" id="Project" order="0" visible="true" weight="0.28202045" />
|
|
338
|
+
<window_info id="Structure" order="1" side_tool="true" weight="0.25" />
|
|
339
|
+
<window_info anchor="bottom" id="Docker" show_stripe_button="false" />
|
|
340
|
+
<window_info anchor="bottom" id="Database Changes" />
|
|
341
|
+
<window_info anchor="bottom" id="Version Control" />
|
|
342
|
+
<window_info anchor="bottom" id="Messages" weight="0.37761378" />
|
|
343
|
+
<window_info anchor="bottom" id="Terminal" visible="true" weight="0.3296433" />
|
|
344
|
+
<window_info anchor="bottom" id="Event Log" side_tool="true" />
|
|
345
|
+
<window_info anchor="bottom" id="Message" order="0" />
|
|
346
|
+
<window_info anchor="bottom" id="Find" order="1" />
|
|
347
|
+
<window_info anchor="bottom" id="Run" order="2" weight="0.3296433" />
|
|
348
|
+
<window_info anchor="bottom" id="Debug" order="3" weight="0.4" />
|
|
349
|
+
<window_info anchor="bottom" id="Cvs" order="4" weight="0.25" />
|
|
350
|
+
<window_info anchor="bottom" id="Inspection" order="5" weight="0.4" />
|
|
351
|
+
<window_info anchor="bottom" id="TODO" order="6" weight="0.3296433" />
|
|
352
|
+
<window_info anchor="right" id="Database" />
|
|
353
|
+
<window_info anchor="right" id="Commander" order="0" weight="0.4" />
|
|
354
|
+
<window_info anchor="right" id="Ant Build" order="1" weight="0.25" />
|
|
355
|
+
<window_info anchor="right" content_ui="combo" id="Hierarchy" order="2" weight="0.25" />
|
|
356
|
+
</layout>
|
|
357
|
+
</component>
|
|
358
|
+
<component name="TypeScriptGeneratedFilesManager">
|
|
359
|
+
<option name="version" value="1" />
|
|
360
|
+
</component>
|
|
361
|
+
<component name="com.intellij.coverage.CoverageDataManagerImpl">
|
|
362
|
+
<SUITE FILE_PATH="coverage/administrate_field_hyperlink@Unnamed.rcov" NAME="Unnamed Coverage Results" MODIFIED="1552649701711" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="rcov" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$" MODULE_NAME="administrate-field-hyperlink" />
|
|
363
|
+
</component>
|
|
364
|
+
<component name="editorHistoryManager">
|
|
365
|
+
<entry file="file://$PROJECT_DIR$/test/test_helper.rb">
|
|
366
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
367
|
+
<state relative-caret-position="34">
|
|
368
|
+
<caret line="2" column="38" selection-start-line="2" selection-start-column="38" selection-end-line="2" selection-end-column="38" />
|
|
369
|
+
</state>
|
|
370
|
+
</provider>
|
|
371
|
+
</entry>
|
|
372
|
+
<entry file="file://$PROJECT_DIR$/lib/administrate/field/hyperlink/version.rb">
|
|
373
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
374
|
+
<state relative-caret-position="68">
|
|
375
|
+
<caret line="4" column="49" selection-start-line="4" selection-start-column="4" selection-end-line="4" selection-end-column="49" />
|
|
376
|
+
</state>
|
|
377
|
+
</provider>
|
|
378
|
+
</entry>
|
|
379
|
+
<entry file="file://C:/Ruby25-x64/lib/ruby/gems/2.5.0/gems/administrate-0.11.0/lib/administrate/field/base.rb">
|
|
380
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
381
|
+
<state relative-caret-position="17">
|
|
382
|
+
<caret line="18" column="10" selection-start-line="18" selection-start-column="10" selection-end-line="18" selection-end-column="10" />
|
|
383
|
+
</state>
|
|
384
|
+
</provider>
|
|
385
|
+
</entry>
|
|
386
|
+
<entry file="file://$PROJECT_DIR$/lib/administrate/field/hyperlink.rb">
|
|
387
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
388
|
+
<state relative-caret-position="272">
|
|
389
|
+
<caret line="16" column="33" selection-start-line="16" selection-start-column="11" selection-end-line="16" selection-end-column="33" />
|
|
390
|
+
</state>
|
|
391
|
+
</provider>
|
|
392
|
+
</entry>
|
|
393
|
+
<entry file="file://$PROJECT_DIR$/Rakefile">
|
|
394
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
395
|
+
<state relative-caret-position="170">
|
|
396
|
+
<caret line="10" selection-start-line="10" selection-end-line="10" />
|
|
397
|
+
</state>
|
|
398
|
+
</provider>
|
|
399
|
+
</entry>
|
|
400
|
+
<entry file="file://$PROJECT_DIR$/test/lib/administrate/field/hyperlink_test.rb">
|
|
401
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
402
|
+
<state relative-caret-position="340">
|
|
403
|
+
<caret line="26" column="21" selection-start-line="26" selection-start-column="21" selection-end-line="26" selection-end-column="21" />
|
|
404
|
+
</state>
|
|
405
|
+
</provider>
|
|
406
|
+
</entry>
|
|
407
|
+
<entry file="file://$PROJECT_DIR$/app/views/fields/hyperlink/_form.html.erb">
|
|
408
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
409
|
+
<state>
|
|
410
|
+
<caret column="3" selection-start-column="3" selection-end-column="3" />
|
|
411
|
+
</state>
|
|
412
|
+
</provider>
|
|
413
|
+
</entry>
|
|
414
|
+
<entry file="file://$PROJECT_DIR$/app/views/fields/hyperlink/_index.html.erb">
|
|
415
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
416
|
+
<state relative-caret-position="102">
|
|
417
|
+
<caret line="6" column="49" selection-start-line="6" selection-end-line="7" />
|
|
418
|
+
</state>
|
|
419
|
+
</provider>
|
|
420
|
+
</entry>
|
|
421
|
+
<entry file="file://$PROJECT_DIR$/app/views/fields/hyperlink/_show.html.erb">
|
|
422
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
423
|
+
<state relative-caret-position="323">
|
|
424
|
+
<caret line="19" selection-start-line="19" selection-end-line="19" />
|
|
425
|
+
<folding>
|
|
426
|
+
<element signature="e#0#392#0#RHTML" expanded="true" />
|
|
427
|
+
</folding>
|
|
428
|
+
</state>
|
|
429
|
+
</provider>
|
|
430
|
+
</entry>
|
|
431
|
+
<entry file="file://$PROJECT_DIR$/README.md">
|
|
432
|
+
<provider selected="true" editor-type-id="split-provider[text-editor;markdown-preview-editor]">
|
|
433
|
+
<state split_layout="SPLIT">
|
|
434
|
+
<first_editor relative-caret-position="280">
|
|
435
|
+
<caret line="68" column="147" selection-start-line="68" selection-start-column="147" selection-end-line="68" selection-end-column="147" />
|
|
436
|
+
</first_editor>
|
|
437
|
+
<second_editor />
|
|
438
|
+
</state>
|
|
439
|
+
</provider>
|
|
440
|
+
</entry>
|
|
441
|
+
<entry file="file://$PROJECT_DIR$/../administrate-base_controller/administrate-base_controller.gemspec">
|
|
442
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
443
|
+
<state relative-caret-position="357">
|
|
444
|
+
<caret line="39" column="54" selection-start-line="39" selection-start-column="54" selection-end-line="39" selection-end-column="54" />
|
|
445
|
+
</state>
|
|
446
|
+
</provider>
|
|
447
|
+
</entry>
|
|
448
|
+
<entry file="file://$PROJECT_DIR$/administrate-field-hyperlink.gemspec">
|
|
449
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
450
|
+
<state relative-caret-position="442">
|
|
451
|
+
<caret line="35" lean-forward="true" selection-start-line="35" selection-end-line="35" />
|
|
452
|
+
</state>
|
|
453
|
+
</provider>
|
|
454
|
+
</entry>
|
|
455
|
+
<entry file="file://$PROJECT_DIR$/Gemfile.lock">
|
|
456
|
+
<provider selected="true" editor-type-id="text-editor">
|
|
457
|
+
<state relative-caret-position="85">
|
|
458
|
+
<caret line="5" column="3" lean-forward="true" selection-start-line="5" selection-start-column="3" selection-end-line="5" selection-end-column="3" />
|
|
459
|
+
</state>
|
|
460
|
+
</provider>
|
|
461
|
+
</entry>
|
|
462
|
+
</component>
|
|
463
|
+
</project>
|
data/CHANGELOG.md
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# CHANGELOG
|
|
2
|
+
|
|
3
|
+
## 1.1.0 (2017-03-24)
|
|
4
|
+
|
|
5
|
+
* Don't crash if image is nil/blank ([#9][])
|
|
6
|
+
* Remove Explicit Dependency on Rails ([#11][])
|
|
7
|
+
* Adds this CHANGELOG ([#12][])
|
|
8
|
+
|
|
9
|
+
[#9]: https://github.com/thoughtbot/administrate-field-image/pull/9
|
|
10
|
+
[#11]: https://github.com/thoughtbot/administrate-field-image/pull/11
|
|
11
|
+
[#12]: https://github.com/thoughtbot/administrate-field-image/pull/12
|
|
12
|
+
|
|
13
|
+
## 1.0.0 (2017-01-16)
|
|
14
|
+
|
|
15
|
+
* Extraction from [administrate][].
|
|
16
|
+
* Rails 5 support.
|
|
17
|
+
|
|
18
|
+
[administrate]: https://github.com/thoughtbot/administrate
|
data/Gemfile
ADDED
data/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
The MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2008-2017 thoughtbot, inc.
|
|
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
|
|
13
|
+
all 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
|
|
21
|
+
THE SOFTWARE.
|
data/README.md
ADDED
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
# Administrate::Field::Hyperlink
|
|
2
|
+
|
|
3
|
+
[](https://travis-ci.com/XPBytes/administrate-field-hyperlink)
|
|
4
|
+
[](https://badge.fury.io/rb/administrate-field-hyperlink)
|
|
5
|
+
[](http://opensource.org/licenses/MIT)
|
|
6
|
+
|
|
7
|
+
A string field that is shows a hyperlink.
|
|
8
|
+
|
|
9
|
+
## Installation
|
|
10
|
+
|
|
11
|
+
Add this line to your application's Gemfile:
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
gem 'administrate-field-hyperlink'
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
And then execute:
|
|
18
|
+
|
|
19
|
+
$ bundle
|
|
20
|
+
|
|
21
|
+
Or install it yourself as:
|
|
22
|
+
|
|
23
|
+
$ gem install administrate-field-hyperlink
|
|
24
|
+
|
|
25
|
+
## Usage
|
|
26
|
+
|
|
27
|
+
```ruby
|
|
28
|
+
require "administrate/base_dashboard"
|
|
29
|
+
|
|
30
|
+
class BookDashboard < Administrate::BaseDashboard
|
|
31
|
+
# ATTRIBUTE_TYPES
|
|
32
|
+
# a hash that describes the type of each of the model's fields.
|
|
33
|
+
#
|
|
34
|
+
# Each different type represents an Administrate::Field object,
|
|
35
|
+
# which determines how the attribute is displayed
|
|
36
|
+
# on pages throughout the dashboard.
|
|
37
|
+
ATTRIBUTE_TYPES = {
|
|
38
|
+
id: Field::String,
|
|
39
|
+
name: Field::String,
|
|
40
|
+
author: Field::BelongsTo,
|
|
41
|
+
public_webste: Field::Hyperlink,
|
|
42
|
+
created_at: Field::DateTime,
|
|
43
|
+
updated_at: Field::DateTime
|
|
44
|
+
}.freeze
|
|
45
|
+
|
|
46
|
+
# ...
|
|
47
|
+
end
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
### Options
|
|
51
|
+
|
|
52
|
+
| option | default | description |
|
|
53
|
+
|--------|-------|-------------|
|
|
54
|
+
| `scheme` | `https://` | Scheme to use if there is none given |
|
|
55
|
+
|
|
56
|
+
## Related
|
|
57
|
+
|
|
58
|
+
- [`Administrate`](https://github.com/thoughtbot/administrate): A Rails engine that helps you put together a super-flexible admin dashboard.
|
|
59
|
+
- [`Administrate::BaseController`](https://github.com/XPBytes/administrate-base_controller): A set of application controller improvements.
|
|
60
|
+
|
|
61
|
+
### Concerns
|
|
62
|
+
|
|
63
|
+
- [`Administrate::DefaultOrder`](https://github.com/XPBytes/administrate-default_order): Sets the default order for a resource in a administrate controller.
|
|
64
|
+
- [`Administrate::SerializedFields`](https://github.com/XPBytes/administrate-serialized_fields): Automatically deserialize administrate fields on form submit.
|
|
65
|
+
|
|
66
|
+
### Fields
|
|
67
|
+
|
|
68
|
+
- [`Administrate::Field::Code`](https://github.com/XPBytes/administrate-field-code): A `text` field that shows code.
|
|
69
|
+
<!-- - [`Administrate::Field::Hyperlink`](https://github.com/XPBytes/administrate-field-hyperlink): A `string` field that is shows a hyperlink. -->
|
|
70
|
+
- [`Adminisrtate::Field::JsonEditor`](https://github.com/XPBytes/administrate-field-json_editor): A `text` field that shows a [JSON editor](https://github.com/josdejong/jsoneditor).
|
|
71
|
+
- [`Administrate::Field::ScopedBelongsTo`](https://github.com/XPBytes/administrate-field-scoped_belongs_to): A `belongs_to` field that yields itself to the scope `lambda`.
|
|
72
|
+
- [`Administrate::Field::ScopedHasMany`](https://github.com/XPBytes/administrate-field-scoped_has_many): A `has_many` field that yields itself to the scope `lambda`.
|
|
73
|
+
- [`Administrate::Field::TimeAgo`](https://github.com/XPBytes/administrate-field-time_ago): A `date_time` field that shows its data as `time_ago` since.
|
|
74
|
+
|
|
75
|
+
## Development
|
|
76
|
+
|
|
77
|
+
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can
|
|
78
|
+
also run `bin/console` for an interactive prompt that will allow you to experiment.
|
|
79
|
+
|
|
80
|
+
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the
|
|
81
|
+
version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version,
|
|
82
|
+
push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
|
83
|
+
|
|
84
|
+
## Contributing
|
|
85
|
+
|
|
86
|
+
Bug reports and pull requests are welcome on GitHub at [XPBytes/administrate-field-hyperlink](https://github.com/XPBytes/administrate-field-hyperlink).
|
data/Rakefile
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
lib = File.expand_path('../lib', __FILE__)
|
|
2
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
3
|
+
require 'administrate/field/hyperlink/version'
|
|
4
|
+
|
|
5
|
+
Gem::Specification.new do |spec|
|
|
6
|
+
spec.name = 'administrate-field-hyperlink'
|
|
7
|
+
spec.version = Administrate::Field::Hyperlink::VERSION
|
|
8
|
+
spec.authors = ['Derk-Jan Karrenbeld']
|
|
9
|
+
spec.email = ['derk-jan@xpbytes.com']
|
|
10
|
+
|
|
11
|
+
spec.summary = 'A string field that is shows a hyperlink.'
|
|
12
|
+
spec.homepage = 'https://github.com/XPBytes/administrate-field-hyperlink'
|
|
13
|
+
spec.license = 'MIT'
|
|
14
|
+
|
|
15
|
+
# Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
|
|
16
|
+
# to allow pushing to a single host or delete this section to allow pushing to any host.
|
|
17
|
+
if spec.respond_to?(:metadata)
|
|
18
|
+
# spec.metadata['allowed_push_host'] = 'TODO: Set to 'http://mygemserver.com''
|
|
19
|
+
|
|
20
|
+
spec.metadata['homepage_uri'] = spec.homepage
|
|
21
|
+
spec.metadata['source_code_uri'] = spec.homepage
|
|
22
|
+
spec.metadata['changelog_uri'] = spec.homepage + '/CHANGELOG.md'
|
|
23
|
+
else
|
|
24
|
+
raise 'RubyGems 2.0 or newer is required to protect against ' \
|
|
25
|
+
'public gem pushes.'
|
|
26
|
+
end
|
|
27
|
+
|
|
28
|
+
# Specify which files should be added to the gem when it is released.
|
|
29
|
+
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
|
|
30
|
+
spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
|
|
31
|
+
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
|
32
|
+
end
|
|
33
|
+
spec.bindir = 'exe'
|
|
34
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
|
35
|
+
spec.require_paths = ['lib']
|
|
36
|
+
|
|
37
|
+
spec.add_development_dependency 'administrate', '>= 0.11.0', '< 1'
|
|
38
|
+
spec.add_development_dependency 'bundler', '~> 2.0'
|
|
39
|
+
spec.add_development_dependency 'minitest', '~> 5.0'
|
|
40
|
+
spec.add_development_dependency 'rake', '~> 10.0'
|
|
41
|
+
end
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
<%#
|
|
2
|
+
# Hyperlink Form Partial
|
|
3
|
+
|
|
4
|
+
This partial renders an input element for a string attribute.
|
|
5
|
+
By default, the input is a string field.
|
|
6
|
+
|
|
7
|
+
## Local variables:
|
|
8
|
+
|
|
9
|
+
- `f`:
|
|
10
|
+
A Rails form generator, used to help create the appropriate input fields.
|
|
11
|
+
- `field`:
|
|
12
|
+
An instance of [Administrate::Field::Hyperlink][1].
|
|
13
|
+
A wrapper around the [Administrate::Field::String][2] field.
|
|
14
|
+
|
|
15
|
+
[1]: http://www.rubydoc.info/gems/administrate-field-hyperlink/Administrate/Field/Hyperlink
|
|
16
|
+
[2]: http://www.rubydoc.info/gems/administrate/Administrate/Field/String
|
|
17
|
+
%>
|
|
18
|
+
|
|
19
|
+
<div class="field-unit__label">
|
|
20
|
+
<%= f.label field.attribute %>
|
|
21
|
+
</div>
|
|
22
|
+
<div class="field-unit__field">
|
|
23
|
+
<%= f.text_field field.attribute %>
|
|
24
|
+
</div>
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<%#
|
|
2
|
+
# Hyperlink Index Partial
|
|
3
|
+
|
|
4
|
+
This partial renders a hyperlink attribute
|
|
5
|
+
to be displayed on a resource's index page.
|
|
6
|
+
|
|
7
|
+
By default, the attribute is rendered as a hyperlink to the data with the truncated string as label.
|
|
8
|
+
|
|
9
|
+
## Local variables:
|
|
10
|
+
|
|
11
|
+
- `field`:
|
|
12
|
+
An instance of [Administrate::Field::Hyperlink][1].
|
|
13
|
+
A wrapper around the [Administrate::Field::String][2] field.
|
|
14
|
+
|
|
15
|
+
[1]: http://www.rubydoc.info/gems/administrate-field-hyperlink/Administrate/Field/Hyperlink
|
|
16
|
+
[2]: http://www.rubydoc.info/gems/administrate/Administrate/Field/String
|
|
17
|
+
%>
|
|
18
|
+
|
|
19
|
+
<%= link_to field.truncate, field.href, target: '_blank', rel: 'noopener noreferrer' %>
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<%#
|
|
2
|
+
# Hyperlink Show Partial
|
|
3
|
+
|
|
4
|
+
This partial renders a hyperlink attribute,
|
|
5
|
+
to be displayed on a resource's show page.
|
|
6
|
+
|
|
7
|
+
By default, the attribute is rendered as a hyperlink to the data with the entire data as label.
|
|
8
|
+
|
|
9
|
+
## Local variables:
|
|
10
|
+
|
|
11
|
+
- `field`:
|
|
12
|
+
An instance of [Administrate::Field::Hyperlink][1].
|
|
13
|
+
A wrapper around the [Administrate::Field::String][2] field.
|
|
14
|
+
|
|
15
|
+
[1]: http://www.rubydoc.info/gems/administrate-field-hyperlink/Administrate/Field/Hyperlink
|
|
16
|
+
[2]: http://www.rubydoc.info/gems/administrate/Administrate/Field/String
|
|
17
|
+
%>
|
|
18
|
+
|
|
19
|
+
<%= link_to field.data, field.href, target: '_blank', rel: 'noopener noreferrer' %>
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
require 'administrate/field/string'
|
|
2
|
+
require 'rails'
|
|
3
|
+
|
|
4
|
+
module Administrate
|
|
5
|
+
module Field
|
|
6
|
+
class Hyperlink < Administrate::Field::String
|
|
7
|
+
class Engine < ::Rails::Engine
|
|
8
|
+
end
|
|
9
|
+
|
|
10
|
+
def to_s
|
|
11
|
+
data
|
|
12
|
+
end
|
|
13
|
+
|
|
14
|
+
def href
|
|
15
|
+
return data if data.include?('://') || data.start_with?('//')
|
|
16
|
+
|
|
17
|
+
"#{options.fetch(:scheme) { 'https://' }}#{data}"
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
end
|
|
21
|
+
end
|
metadata
ADDED
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
|
2
|
+
name: administrate-field-hyperlink
|
|
3
|
+
version: !ruby/object:Gem::Version
|
|
4
|
+
version: 0.1.0
|
|
5
|
+
platform: ruby
|
|
6
|
+
authors:
|
|
7
|
+
- Derk-Jan Karrenbeld
|
|
8
|
+
autorequire:
|
|
9
|
+
bindir: exe
|
|
10
|
+
cert_chain: []
|
|
11
|
+
date: 2019-03-15 00:00:00.000000000 Z
|
|
12
|
+
dependencies:
|
|
13
|
+
- !ruby/object:Gem::Dependency
|
|
14
|
+
name: administrate
|
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
|
16
|
+
requirements:
|
|
17
|
+
- - ">="
|
|
18
|
+
- !ruby/object:Gem::Version
|
|
19
|
+
version: 0.11.0
|
|
20
|
+
- - "<"
|
|
21
|
+
- !ruby/object:Gem::Version
|
|
22
|
+
version: '1'
|
|
23
|
+
type: :development
|
|
24
|
+
prerelease: false
|
|
25
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
26
|
+
requirements:
|
|
27
|
+
- - ">="
|
|
28
|
+
- !ruby/object:Gem::Version
|
|
29
|
+
version: 0.11.0
|
|
30
|
+
- - "<"
|
|
31
|
+
- !ruby/object:Gem::Version
|
|
32
|
+
version: '1'
|
|
33
|
+
- !ruby/object:Gem::Dependency
|
|
34
|
+
name: bundler
|
|
35
|
+
requirement: !ruby/object:Gem::Requirement
|
|
36
|
+
requirements:
|
|
37
|
+
- - "~>"
|
|
38
|
+
- !ruby/object:Gem::Version
|
|
39
|
+
version: '2.0'
|
|
40
|
+
type: :development
|
|
41
|
+
prerelease: false
|
|
42
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
43
|
+
requirements:
|
|
44
|
+
- - "~>"
|
|
45
|
+
- !ruby/object:Gem::Version
|
|
46
|
+
version: '2.0'
|
|
47
|
+
- !ruby/object:Gem::Dependency
|
|
48
|
+
name: minitest
|
|
49
|
+
requirement: !ruby/object:Gem::Requirement
|
|
50
|
+
requirements:
|
|
51
|
+
- - "~>"
|
|
52
|
+
- !ruby/object:Gem::Version
|
|
53
|
+
version: '5.0'
|
|
54
|
+
type: :development
|
|
55
|
+
prerelease: false
|
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
57
|
+
requirements:
|
|
58
|
+
- - "~>"
|
|
59
|
+
- !ruby/object:Gem::Version
|
|
60
|
+
version: '5.0'
|
|
61
|
+
- !ruby/object:Gem::Dependency
|
|
62
|
+
name: rake
|
|
63
|
+
requirement: !ruby/object:Gem::Requirement
|
|
64
|
+
requirements:
|
|
65
|
+
- - "~>"
|
|
66
|
+
- !ruby/object:Gem::Version
|
|
67
|
+
version: '10.0'
|
|
68
|
+
type: :development
|
|
69
|
+
prerelease: false
|
|
70
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
71
|
+
requirements:
|
|
72
|
+
- - "~>"
|
|
73
|
+
- !ruby/object:Gem::Version
|
|
74
|
+
version: '10.0'
|
|
75
|
+
description:
|
|
76
|
+
email:
|
|
77
|
+
- derk-jan@xpbytes.com
|
|
78
|
+
executables: []
|
|
79
|
+
extensions: []
|
|
80
|
+
extra_rdoc_files: []
|
|
81
|
+
files:
|
|
82
|
+
- ".gitignore"
|
|
83
|
+
- ".idea/.rakeTasks"
|
|
84
|
+
- ".idea/administrate-field-hyperlink.iml"
|
|
85
|
+
- ".idea/misc.xml"
|
|
86
|
+
- ".idea/modules.xml"
|
|
87
|
+
- ".idea/vcs.xml"
|
|
88
|
+
- ".idea/workspace.xml"
|
|
89
|
+
- CHANGELOG.md
|
|
90
|
+
- Gemfile
|
|
91
|
+
- LICENSE
|
|
92
|
+
- README.md
|
|
93
|
+
- Rakefile
|
|
94
|
+
- administrate-field-hyperlink.gemspec
|
|
95
|
+
- app/views/fields/hyperlink/_form.html.erb
|
|
96
|
+
- app/views/fields/hyperlink/_index.html.erb
|
|
97
|
+
- app/views/fields/hyperlink/_show.html.erb
|
|
98
|
+
- lib/administrate/field/hyperlink.rb
|
|
99
|
+
- lib/administrate/field/hyperlink/version.rb
|
|
100
|
+
homepage: https://github.com/XPBytes/administrate-field-hyperlink
|
|
101
|
+
licenses:
|
|
102
|
+
- MIT
|
|
103
|
+
metadata:
|
|
104
|
+
homepage_uri: https://github.com/XPBytes/administrate-field-hyperlink
|
|
105
|
+
source_code_uri: https://github.com/XPBytes/administrate-field-hyperlink
|
|
106
|
+
changelog_uri: https://github.com/XPBytes/administrate-field-hyperlink/CHANGELOG.md
|
|
107
|
+
post_install_message:
|
|
108
|
+
rdoc_options: []
|
|
109
|
+
require_paths:
|
|
110
|
+
- lib
|
|
111
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
|
112
|
+
requirements:
|
|
113
|
+
- - ">="
|
|
114
|
+
- !ruby/object:Gem::Version
|
|
115
|
+
version: '0'
|
|
116
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
117
|
+
requirements:
|
|
118
|
+
- - ">="
|
|
119
|
+
- !ruby/object:Gem::Version
|
|
120
|
+
version: '0'
|
|
121
|
+
requirements: []
|
|
122
|
+
rubyforge_project:
|
|
123
|
+
rubygems_version: 2.7.6
|
|
124
|
+
signing_key:
|
|
125
|
+
specification_version: 4
|
|
126
|
+
summary: A string field that is shows a hyperlink.
|
|
127
|
+
test_files: []
|