Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Canal Ciência
Plugin Omeka WP
Commits
499bdd35
Commit
499bdd35
authored
2 years ago
by
André Togawa
Browse files
Options
Download
Email Patches
Plain Diff
Ajustes de commit
parent
233169b3
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
124 additions
and
15 deletions
+124
-15
build/index.asset.php
build/index.asset.php
+1
-1
build/index.js
build/index.js
+60
-8
build/index.js.map
build/index.js.map
+1
-1
js/on_page_load.js
js/on_page_load.js
+1
-1
src/index.js
src/index.js
+61
-4
No files found.
build/index.asset.php
View file @
499bdd35
<?php
return
array
(
'dependencies'
=>
array
(
'wp-element'
),
'version'
=>
'72f217ef5a447bd4c906727fd6e41f8e'
);
\ No newline at end of file
<?php
return
array
(
'dependencies'
=>
array
(
'wp-element'
),
'version'
=>
'4e9efe4469913bf24565417feca5bc0d'
);
\ No newline at end of file
This diff is collapsed.
Click to expand it.
build/index.js
View file @
499bdd35
...
...
@@ -342,7 +342,7 @@ registerBlockType('getod/getod-audio', {
registerBlockType
(
'
getod/getod-miniloop
'
,
{
title
:
'
Omeka: Miniloop
'
,
description
:
'
Bloco Miniloop, Insira um MetadataID, um loop povando os blocos
dentro d
este
bloco
irá ser realizado.
'
,
description
:
'
Loop
dentro d
os
bloco
s
'
,
icon
:
'
rest-api
'
,
category
:
'
common
'
,
keywords
:
[
'
loop
'
,
'
mini
'
,
'
miniloop
'
,
'
omeka
'
,
'
geod
'
],
...
...
@@ -367,9 +367,8 @@ registerBlockType('getod/getod-miniloop', {
placeholder
:
"
MetadataID
"
,
value
:
props
.
attributes
.
GetOD_Miniloop
,
onChange
:
updateMiniloop
}),
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
"
br
"
,
null
)),
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
InnerBlocks
,
{
allowedBlocks
:
ALLOWED_BLOCKS_GROUP
}));
}),
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
"
br
"
,
null
)),
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
InnerBlocks
//allowedBlocks={ ALLOWED_BLOCKS_GROUP }
,
null
));
},
save
:
function
(
props
)
{
return
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
Fragment
,
null
,
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
"
div
"
,
{
...
...
@@ -435,9 +434,8 @@ registerBlockType('getod/getod-itemsetloop', {
placeholder
:
"
Set ID
"
,
value
:
props
.
attributes
.
itensPerPage
,
onChange
:
updateItensPerPage
}),
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
"
br
"
,
null
)),
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
InnerBlocks
,
{
allowedBlocks
:
ALLOWED_BLOCKS_GROUP
})),
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
InspectorControls
,
null
,
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
PanelBody
,
{
}),
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
"
br
"
,
null
)),
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
InnerBlocks
//allowedBlocks={ ALLOWED_BLOCKS_GROUP }
,
null
)),
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
InspectorControls
,
null
,
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
PanelBody
,
{
title
:
"
Sort By
"
,
initialOpen
:
true
},
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
TextControl
,
{
...
...
@@ -538,6 +536,60 @@ registerBlockType('getod/getod-itemsetloop-url', {
href
:
props
.
attributes
.
UrlPage
},
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
InnerBlocks
.
Content
,
null
))));
}
});
//== Block GetOD: SubFields ===============================================================
registerBlockType
(
'
getod/getod-subfields
'
,
{
title
:
'
Omeka: Sub Fields
'
,
description
:
'
Bloco baixar sub campos
'
,
icon
:
'
rest-api
'
,
category
:
'
common
'
,
keywords
:
[
'
subfield
'
,
'
set
'
,
'
sub field
'
,
'
item
'
,
'
omeka
'
,
'
geod
'
],
attributes
:
{
GetOD_subfield
:
{
type
:
"
string
"
},
GetOD_objectName
:
{
type
:
"
string
"
}
},
edit
:
function
(
props
)
{
function
updateObjectName
(
event
)
{
props
.
setAttributes
({
GetOD_objectName
:
event
.
target
.
value
});
}
function
updateSubField
(
event
)
{
props
.
setAttributes
({
GetOD_subfield
:
event
.
target
.
value
});
}
return
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
"
div
"
,
{
className
:
"
omeka-plugin-interno-border omeka-plugin-interno
"
},
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
"
div
"
,
{
className
:
"
omeka-plugin-interno-comentario
"
},
"
Omeka | Sub field:
"
,
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
"
input
"
,
{
type
:
"
text
"
,
placeholder
:
"
Sub field
"
,
value
:
props
.
attributes
.
GetOD_subfield
,
onChange
:
updateSubField
}),
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
"
br
"
,
null
),
"
Omeka | Object Name:
"
,
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
"
input
"
,
{
type
:
"
text
"
,
placeholder
:
"
Object Name
"
,
value
:
props
.
attributes
.
updateObjectName
,
onChange
:
updateObjectName
})),
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
InnerBlocks
//allowedBlocks={ ALLOWED_BLOCKS_ALL }
,
null
));
},
save
:
function
(
props
)
{
return
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
Fragment
,
null
,
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
"
div
"
,
{
className
:
"
getod getod-item-set-url getod-empty
"
,
getod_block
:
"
getod-item-set-url
"
},
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
"
a
"
,
{
href
:
props
.
attributes
.
GetOD_subfield
},
(
0
,
_wordpress_element__WEBPACK_IMPORTED_MODULE_0__
.
createElement
)(
InnerBlocks
.
Content
,
null
))));
}
});
//== Block GetOD: Pagination=========================================================================
registerBlockType
(
'
getod/getod-pagination
'
,
{
...
...
@@ -671,7 +723,7 @@ registerBlockType('getod/getod-url', {
});
//== Block GetOD: listFullFields =========================================================================
registerBlockType
(
'
getod/getod-listfullfields
'
,
{
title
:
'
Omeka: ListFullFields
'
,
title
:
'
Omeka: ListFullFields
'
,
description
:
'
Bloco para listar todos os campos de um determinado metadado
'
,
icon
:
'
rest-api
'
,
category
:
'
common
'
,
...
...
This diff is collapsed.
Click to expand it.
build/index.js.map
View file @
499bdd35
This diff is collapsed.
Click to expand it.
js/on_page_load.js
View file @
499bdd35
...
...
@@ -523,7 +523,7 @@ function PopulateFields(jasonData, divItem, loopType){
let
imgAccessRights
=
divItem
[
i
].
getAttribute
(
"
getod_image_accessRights
"
);
let
imgRightsHolder
=
divItem
[
i
].
getAttribute
(
"
getod_image_rightsHolder
"
);
if
(
imgUrl
){
if
(
imgUrl
&&
(
imgUrl
!=
null
)
){
if
(
imgUrl
==
'
null
'
){
item
.
classList
.
remove
(
"
getod-empty-image
"
);
}
...
...
This diff is collapsed.
Click to expand it.
src/index.js
View file @
499bdd35
...
...
@@ -233,7 +233,7 @@ const ALLOWED_BLOCKS_GROUP = ['core/group'];
registerBlockType
(
'
getod/getod-miniloop
'
,
{
title
:
'
Omeka: Miniloop
'
,
description
:
'
Bloco Miniloop, Insira um MetadataID, um loop povando os blocos
dentro d
este
bloco
irá ser realizado.
'
,
description
:
'
Loop
dentro d
os
bloco
s
'
,
icon
:
'
rest-api
'
,
category
:
'
common
'
,
keywords
:
[
'
loop
'
,
'
mini
'
,
'
miniloop
'
,
'
omeka
'
,
'
geod
'
],
...
...
@@ -256,7 +256,7 @@ const ALLOWED_BLOCKS_GROUP = ['core/group'];
<
br
><
/br
>
<
/div
>
<
InnerBlocks
allowedBlocks
=
{
ALLOWED_BLOCKS_GROUP
}
//
allowedBlocks={ ALLOWED_BLOCKS_GROUP }
/>
<
/div>
)
...
...
@@ -318,7 +318,7 @@ const ALLOWED_BLOCKS_GROUP = ['core/group'];
<
/div
>
<
InnerBlocks
allowedBlocks
=
{
ALLOWED_BLOCKS_GROUP
}
//
allowedBlocks={ ALLOWED_BLOCKS_GROUP }
/>
<
/div>
<
InspectorControls
>
...
...
@@ -493,6 +493,63 @@ registerBlockType('getod/getod-itemsetloop-url', {
});
//== Block GetOD: SubFields ===============================================================
registerBlockType(
'
getod
/
getod
-
subfields
'
, {
title:
'
Omeka
:
Sub
Fields
'
,
description:
'
Bloco
baixar
sub
campos
'
,
icon:
'
rest
-
api
'
,
category:
'
common
'
,
keywords: [
'
subfield
'
,
'
set
'
,
'
sub
field
'
,
'
item
'
,
'
omeka
'
,
'
geod
'
],
attributes: {
GetOD_subfield: {type: "string" } ,
GetOD_objectName: {type: "string" }
},
edit: function(props){
function updateObjectName(event){
props.setAttributes({GetOD_objectName: event.target.value})
}
function updateSubField(event){
props.setAttributes({GetOD_subfield: event.target.value})
}
return (
<div className="omeka-plugin-interno-border omeka-plugin-interno">
<div className="omeka-plugin-interno-comentario">
Omeka | Sub field: <input type="text"
placeholder="Sub field"
value={props.attributes.GetOD_subfield}
onChange={updateSubField} />
<br></br>
Omeka | Object Name: <input type="text" placeholder="Object Name" value={props.attributes.updateObjectName} onChange={updateObjectName} />
</div>
<InnerBlocks
//allowedBlocks={ ALLOWED_BLOCKS_ALL }
/>
</div>
)
},
save: function(props){
return (
<>
<div className="getod getod-item-set-url getod-empty" getod_block ="getod-item-set-url">
<a href= {props.attributes.GetOD_subfield} >
<InnerBlocks.Content/>
</a>
</div>
</>
)
},
});
//== Block GetOD: Pagination=========================================================================
registerBlockType(
'
getod
/
getod
-
pagination
'
, {
...
...
@@ -638,7 +695,7 @@ registerBlockType('getod/getod-url', {
registerBlockType(
'
getod
/
getod
-
listfullfields
'
, {
title:
'
Omeka
:
ListFullFields
'
,
title:
'
Omeka
:
ListFullFields
'
,
description:
'
Bloco
para
listar
todos
os
campos
de
um
determinado
metadado
'
,
icon:
'
rest
-
api
'
,
category:
'
common
'
,
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment