Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE] Support for musical sources (and prototype annotations) #952

Merged
Merged
Show file tree
Hide file tree
Changes from 41 commits
Commits
Show all changes
119 commits
Select commit Hold shift + click to select a range
c4624e6
Read Score Data by new USE Attribute
May 3, 2022
01acbe3
Add Verovio Toolkit
May 3, 2022
f37d075
Integrate Verovio Toolkit
May 3, 2022
6f7555d
Add getPageBeginning Method
May 18, 2022
fd5d859
Scroll to Pagebeginning
May 18, 2022
20fc2ad
Read Score Data by new USE Attribute
May 3, 2022
8cac53e
Full text branch
hizclick Aug 18, 2022
c090bd4
midiplayer
hizclick Aug 18, 2022
eb75fa8
Add mini player play button
hizclick Aug 24, 2022
31ff1d8
add Midi player
hizclick Aug 24, 2022
f933925
Verovio integration updated
roewenstrunk Oct 25, 2022
75b9f45
this is verovio toolkit update
hizclick Nov 25, 2022
487db72
saveas.js
hizclick Nov 25, 2022
67deb6b
Midi player test
hizclick Dec 6, 2022
1e658c3
Open Layers for Verovio
roewenstrunk Dec 13, 2022
904f541
Use the global variable for toolkit
roewenstrunk Dec 21, 2022
49543bf
Rendering of Scores
roewenstrunk Jan 20, 2023
341ed54
loading webmidi
hizclick Feb 7, 2023
c1ed25f
Load wildwebmidi.data
roewenstrunk Feb 7, 2023
8452961
Extended MetsDocument for the new musical struct.
haogatyp Apr 6, 2023
336debd
Added cross-page navigation for measures.
haogatyp Apr 27, 2023
1b28c62
structMap musical xpath adjustments and read coords from mets into mu…
chrizzor May 31, 2023
66048c3
Read in measure information and make it available in the javascript
chrizzor May 31, 2023
2fc9018
Add measure layer with select option. Layer is only visible if score …
chrizzor May 31, 2023
809ba58
Add sync control and add projection to scoreMap
chrizzor Jun 12, 2023
a594728
Add annotation feature.
haogatyp Jun 18, 2023
47688ba
Add gridstack to load multiple documents
chrizzor Jun 30, 2023
d7c2be6
Merge branch 'midi-player-annotations' into midi-player-navigation
chrizzor Jun 30, 2023
8a30d81
Add gridstack lib
chrizzor Jun 30, 2023
7d93e80
Add form model to use multiple sources
chrizzor Jul 3, 2023
f550bcb
Add form model to use multiple sources
chrizzor Jul 3, 2023
21f8854
Annotations: Write semicolon separated ranges in data attributes inst…
haogatyp Jul 3, 2023
d0ca4da
Merge branch 'midi-player-navigation' of github.com:effective-webwork…
chrizzor Jul 4, 2023
e75ea36
Add multiview parameter and define global navigation for multiview
chrizzor Jul 6, 2023
61b99aa
Add annotation interaction with openlayers
chrizzor Jul 6, 2023
5e203ab
Add a hover event from the html annotation
chrizzor Jul 6, 2023
6d0d75f
use file group to build a measure to page array
chrizzor Jul 14, 2023
0850200
Add measure/page navigation for pageview
chrizzor Jul 14, 2023
c8ea6b8
Select current measure on measure navigation
chrizzor Jul 17, 2023
774217b
Merge branch 'slub_master' into midi-player-navigation
chrizzor Sep 4, 2023
46c9344
Move the DocPage parameter, because the parameters are now handled in…
chrizzor Sep 4, 2023
91a4bc3
Codacy changes
chrizzor Sep 4, 2023
6bf6f84
Add placeholder function
chrizzor Sep 4, 2023
3f71fdf
Adjustment isDocMissingOrEmpty for type multiview
chrizzor Sep 15, 2023
27e9fca
Convert tabs to spaces
chrizzor Sep 15, 2023
09f8261
Move gridstack.js to PageView directory
chrizzor Sep 15, 2023
7fc3888
Codacy fix
chrizzor Sep 15, 2023
6467d08
Convert tabs to spaces
chrizzor Sep 15, 2023
64ce1ff
Merge branch 'master' into midi-player-navigation
chrizzor Jul 1, 2024
e2bdccb
Fix PHPStan Static Analysis
chrizzor Jul 2, 2024
02934c8
Merge branch 'main_master' into midi-player-navigation
chrizzor Jul 2, 2024
1b1e029
Remove conflict comments
chrizzor Jul 2, 2024
2d10270
Fix PHPStan
chrizzor Jul 3, 2024
8b6b40f
Fix PHPStan
chrizzor Jul 3, 2024
40028a4
Codacy fix
chrizzor Jul 3, 2024
3ac82bb
Fix wrong javascript folder name
chrizzor Jul 4, 2024
07ebe08
Fix wrong javascript folder name
chrizzor Jul 4, 2024
1d1f7a8
Remove .DS_Store and ignore them
chrizzor Jul 4, 2024
bb9848f
Use "magicGet" for musicalStructure
chrizzor Jul 4, 2024
787318f
Load gridstack js only if multiview parameter is set
chrizzor Jul 4, 2024
b32a002
Add changes from project-slub
chrizzor Jul 5, 2024
a097b97
Fix PHPStan
chrizzor Jul 5, 2024
804c05f
Fix measure view and verovio
chrizzor Jul 5, 2024
be539fe
Fix problem with JavaScript folder
chrizzor Jul 8, 2024
466239e
Fix JavaScript folder problems
chrizzor Jul 8, 2024
3c7de9f
Rename tmp folder to JavaScript
chrizzor Jul 8, 2024
7d2c596
Fix folder names in typoscript configuration
chrizzor Jul 8, 2024
4645f91
Comment out css changes for midiplayer
chrizzor Jul 8, 2024
5921bf0
Merge branch 'slub_master' into midi-player-navigation
chrizzor Jul 8, 2024
6e68aff
Update .gitignore
chrizzor Jul 8, 2024
cc1d0bc
Remove .DS_Store
chrizzor Jul 8, 2024
7071697
Update Classes/Common/MetsDocument.php
chrizzor Jul 8, 2024
2c01425
Update Classes/Common/MetsDocument.php
chrizzor Jul 8, 2024
13603d4
Update Resources/Public/JavaScript/PageView/ScoreUtility.js
chrizzor Jul 8, 2024
4773c61
Update Resources/Public/JavaScript/PageView/ScoreUtility.js
chrizzor Jul 8, 2024
fd30873
Update Resources/Public/JavaScript/PageView/ScoreUtility.js
chrizzor Jul 8, 2024
6dda78d
Update Resources/Public/JavaScript/PageView/SyncControl.js
chrizzor Jul 8, 2024
cadff9d
Update Resources/Public/JavaScript/PageView/SyncControl.js
chrizzor Jul 8, 2024
d87d2df
Update Classes/Common/MetsDocument.php
chrizzor Jul 8, 2024
79366cc
Update Classes/Common/MetsDocument.php
chrizzor Jul 8, 2024
c39e368
Update Classes/Common/MetsDocument.php
chrizzor Jul 8, 2024
f5d4156
Apply suggestions from code review
chrizzor Jul 8, 2024
53d3d57
Remove inactive code
chrizzor Jul 8, 2024
e58ad14
[MAINTENANCE] Bump phpstan/phpstan from 1.11.1 to 1.11.7 (#1269)
dependabot[bot] Jul 8, 2024
92d72bd
Remove annotation dev configuration
chrizzor Jul 8, 2024
5efe24e
Remove files
chrizzor Jul 8, 2024
04cd5dd
Apply suggestions from code review
chrizzor Jul 8, 2024
55d235d
Exempt Gridstack and Verovio from automated quality checks
chrizzor Jul 8, 2024
8542dc0
Merge branch 'midi-player-navigation' of github.com:effective-webwork…
chrizzor Jul 8, 2024
371076f
[BUGFIX] Fix SearchInDocument middleware (#1248)
beatrycze-volk Jul 9, 2024
b089b8d
[BUGFIX] Fix 'Undefined array key `fulltext`' in `SolrSearch` (#1270)
beatrycze-volk Jul 11, 2024
7e11f6a
[BUGFIX] Add $field to the facetset otherwise the name of the field d…
chrizzor Jul 11, 2024
e52dd87
[BUGFIX] Add fallback for `SC_OPTIONS` for case when it is defined in…
beatrycze-volk Jul 11, 2024
df777d7
Apply suggestions from code review
chrizzor Jul 15, 2024
9c2b72a
Codacy fix
chrizzor Jul 15, 2024
b262787
Merge branch 'midi-player-navigation' of github.com:effective-webwork…
chrizzor Jul 15, 2024
842073d
Apply suggestions from code review
chrizzor Jul 15, 2024
0a23906
Add missing specificDoc in PHPDoc
chrizzor Jul 15, 2024
40bc91b
Apply suggestions for mediaplayer.js
chrizzor Jul 15, 2024
742f2fb
Delete the duplicate mediaplayer.js, move it to PageView and change t…
chrizzor Jul 15, 2024
4c324ee
Move wildwebmidi.js to verovio
chrizzor Jul 15, 2024
ee8c48c
Apply suggestions from code review
chrizzor Jul 15, 2024
c8d37ae
Remove inheritDoc from getPageBeginning
chrizzor Jul 15, 2024
b463076
Avoid using globals
chrizzor Jul 15, 2024
a63f263
Codacy fix PageViewController
chrizzor Jul 15, 2024
ca2e382
Use AbstractDocument as parameter type
chrizzor Jul 15, 2024
a5707f9
Move gridstack.min.css to JavaScript/Gridstack
chrizzor Jul 15, 2024
fb3a4b9
Codacy quickfix
chrizzor Jul 15, 2024
752fff6
Codacy fix SyncControl
chrizzor Jul 15, 2024
94e9c0f
[FEATURE] Scheduler tasks for indexing, reindexing and harvesting of …
frank-ulrich-weber Jul 16, 2024
13e4ebb
Apply suggestions from code review
chrizzor Jul 16, 2024
d9a8cef
Merge branch 'master' into midi-player-navigation
chrizzor Jul 16, 2024
3a7bfc3
Ensure that it is a MetsDocument when calling the musical methods
chrizzor Jul 16, 2024
a02bf24
Remove PHPStan ignore comment
chrizzor Jul 16, 2024
d960294
Ensure that it is a MetsDocument when calling the musical methods
chrizzor Jul 16, 2024
f31c1e6
Fix "variable might not be defined"
chrizzor Jul 16, 2024
1952af5
Ensure that it is a MetsDocument when calling the musical methods
chrizzor Jul 16, 2024
ff8c619
Ensure that it is a MetsDocument when calling the musical methods
chrizzor Jul 16, 2024
ed7651a
Add PHPDocblock and add missing semicolon
chrizzor Jul 16, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added .DS_Store
Binary file not shown.
Binary file added Build/.DS_Store
sebastian-meyer marked this conversation as resolved.
Show resolved Hide resolved
Binary file not shown.
Binary file added Build/Documentation/.DS_Store
sebastian-meyer marked this conversation as resolved.
Show resolved Hide resolved
Binary file not shown.
78 changes: 78 additions & 0 deletions Classes/Common/AnnotationRequest.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
<?php

namespace Kitodo\Dlf\Common;

/**
* (c) Kitodo. Key to digital objects e.V. <[email protected]>
*
* This file is part of the Kitodo and TYPO3 projects.
*
* @license GNU General Public License version 3 or later.
* For the full copyright and license information, please read the
* LICENSE.txt file that was distributed with this source code.
*/

class AnnotationRequest
{
/**
* @var string
*/
protected $apiUrl = '';

/**
* @param string $apiUrl The url of the annotation server api.
*/
public function __construct($apiUrl)
{
$this->apiUrl = trim($apiUrl, "/ ");
}


/**
* Requests the annotation server
*
* @param string $url The annotation request url.
* @return array
*/
protected function requestAnnotions($url) : array
{
$jsonld = Helper::getUrl($url);

if ($jsonld) {
$annotationData = json_decode($jsonld, true);

if ($annotationData) {
return $annotationData;
}
}

return [];
}

/**
* Returns all annotations of a document.
*
* @param string $id Document id (purl)
* @return array
*/
public function getAll($id)
{
$annotations = [];

$annotationData = $this->requestAnnotions($this->apiUrl . '?target=' . urlencode($id . '/*'));

if (array_key_exists('first', $annotationData)) {
$annotationPageData = $annotationData['first'];
$annotations = array_merge($annotations, $annotationPageData["items"]);

while (array_key_exists('next', $annotationPageData)) {
$annotationPageData = $this->requestAnnotions($annotationPageData['next']);
if (array_key_exists('items', $annotationPageData)) {
$annotations = array_merge($annotations, $annotationPageData["items"]);
}
}
}

return $annotations;
}
}
14 changes: 14 additions & 0 deletions Classes/Common/Doc.php
Original file line number Diff line number Diff line change
Expand Up @@ -378,6 +378,20 @@ public abstract function getDownloadLocation($id);
*/
public abstract function getFileLocation($id);

/**
* Returns id of pb element representing the beginning of a physical page
*
* @access public
*
* @abstract
*
* @param string $pageId: The "@ID" attribute of the page node (METS)
* @param string $fileId: The "@ID" attribute of the file node (METS)
*
* @return string The node's id
*/
public abstract function getPageBeginning($pageId, $fileId);

/**
* This gets the MIME type of a file representing a physical page or track
*
Expand Down
Loading
Loading