Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Mirador Video
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
IIIF
Mirador
Mirador Video
Commits
9d65d2a1
Commit
9d65d2a1
authored
Jun 17, 2019
by
Camille Villa
Browse files
Options
Downloads
Patches
Plain Diff
Adjust styling for 'more' link in content search results
parent
c0806c2b
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/components/SearchHit.js
+8
-2
8 additions, 2 deletions
src/components/SearchHit.js
src/containers/SearchHit.js
+3
-1
3 additions, 1 deletion
src/containers/SearchHit.js
src/locales/en/translation.json
+1
-1
1 addition, 1 deletion
src/locales/en/translation.json
with
12 additions
and
4 deletions
src/components/SearchHit.js
+
8
−
2
View file @
9d65d2a1
...
@@ -36,6 +36,7 @@ export class SearchHit extends Component {
...
@@ -36,6 +36,7 @@ export class SearchHit extends Component {
annotationLabel
,
annotationLabel
,
canvasLabel
,
canvasLabel
,
classes
,
classes
,
companionWindowId
,
containerRef
,
containerRef
,
hit
,
hit
,
focused
,
focused
,
...
@@ -49,6 +50,7 @@ export class SearchHit extends Component {
...
@@ -49,6 +50,7 @@ export class SearchHit extends Component {
const
truncatedHit
=
focused
?
hit
:
hit
&&
new
TruncatedHit
(
hit
);
const
truncatedHit
=
focused
?
hit
:
hit
&&
new
TruncatedHit
(
hit
);
const
truncated
=
hit
&&
truncatedHit
.
before
!==
hit
.
before
&&
truncatedHit
.
after
!==
hit
.
after
;
const
truncated
=
hit
&&
truncatedHit
.
before
!==
hit
.
before
&&
truncatedHit
.
after
!==
hit
.
after
;
const
canvasLabelHtmlId
=
`
${
companionWindowId
}
-
${
index
}
`
;
return
(
return
(
<
ScrollTo
<
ScrollTo
...
@@ -73,7 +75,9 @@ export class SearchHit extends Component {
...
@@ -73,7 +75,9 @@ export class SearchHit extends Component {
<
ListItemText
primaryTypographyProps
=
{{
variant
:
'
body1
'
}}
>
<
ListItemText
primaryTypographyProps
=
{{
variant
:
'
body1
'
}}
>
<
Typography
variant
=
"
subtitle2
"
className
=
{
classes
.
subtitle
}
>
<
Typography
variant
=
"
subtitle2
"
className
=
{
classes
.
subtitle
}
>
<
Chip
component
=
"
span
"
label
=
{
index
+
1
}
className
=
{
classes
.
hitCounter
}
/
>
<
Chip
component
=
"
span
"
label
=
{
index
+
1
}
className
=
{
classes
.
hitCounter
}
/
>
<
span
id
=
{
canvasLabelHtmlId
}
>
{
canvasLabel
}
{
canvasLabel
}
<
/span
>
<
/Typography
>
<
/Typography
>
{
annotationLabel
&&
(
{
annotationLabel
&&
(
<
Typography
variant
=
"
subtitle2
"
>
{
annotationLabel
}
<
/Typography
>
<
Typography
variant
=
"
subtitle2
"
>
{
annotationLabel
}
<
/Typography
>
...
@@ -89,7 +93,7 @@ export class SearchHit extends Component {
...
@@ -89,7 +93,7 @@ export class SearchHit extends Component {
<
SanitizedHtml
ruleSet
=
"
iiif
"
htmlString
=
{
truncatedHit
.
after
}
/
>
<
SanitizedHtml
ruleSet
=
"
iiif
"
htmlString
=
{
truncatedHit
.
after
}
/
>
{
'
'
}
{
'
'
}
{
truncated
&&
!
focused
&&
(
{
truncated
&&
!
focused
&&
(
<
Button
className
=
{
classes
.
inlineButton
}
onClick
=
{
showDetails
}
color
=
"
secondary
"
size
=
"
small
"
>
<
Button
className
=
{
classes
.
inlineButton
}
onClick
=
{
showDetails
}
color
=
"
secondary
"
size
=
"
small
"
aria
-
describedby
=
{
canvasLabelHtmlId
}
>
{
t
(
'
more
'
)}
{
t
(
'
more
'
)}
<
/Button
>
<
/Button
>
)}
)}
...
@@ -112,6 +116,7 @@ SearchHit.propTypes = {
...
@@ -112,6 +116,7 @@ SearchHit.propTypes = {
annotationLabel
:
PropTypes
.
string
,
annotationLabel
:
PropTypes
.
string
,
canvasLabel
:
PropTypes
.
string
,
canvasLabel
:
PropTypes
.
string
,
classes
:
PropTypes
.
objectOf
(
PropTypes
.
string
),
classes
:
PropTypes
.
objectOf
(
PropTypes
.
string
),
companionWindowId
:
PropTypes
.
string
,
containerRef
:
PropTypes
.
oneOfType
([
containerRef
:
PropTypes
.
oneOfType
([
PropTypes
.
func
,
PropTypes
.
func
,
PropTypes
.
shape
({
current
:
PropTypes
.
instanceOf
(
Element
)
}),
PropTypes
.
shape
({
current
:
PropTypes
.
instanceOf
(
Element
)
}),
...
@@ -137,6 +142,7 @@ SearchHit.defaultProps = {
...
@@ -137,6 +142,7 @@ SearchHit.defaultProps = {
annotationLabel
:
undefined
,
annotationLabel
:
undefined
,
canvasLabel
:
undefined
,
canvasLabel
:
undefined
,
classes
:
{},
classes
:
{},
companionWindowId
:
undefined
,
containerRef
:
undefined
,
containerRef
:
undefined
,
focused
:
false
,
focused
:
false
,
hit
:
undefined
,
hit
:
undefined
,
...
...
This diff is collapsed.
Click to expand it.
src/containers/SearchHit.js
+
3
−
1
View file @
9d65d2a1
...
@@ -59,9 +59,11 @@ const styles = theme => ({
...
@@ -59,9 +59,11 @@ const styles = theme => ({
verticalAlign
:
'
inherit
'
,
verticalAlign
:
'
inherit
'
,
},
},
inlineButton
:
{
inlineButton
:
{
'
& span
'
:
{
lineHeight
:
'
1.5em
'
,
},
margin
:
0
,
margin
:
0
,
padding
:
0
,
padding
:
0
,
textDecoration
:
'
underline
'
,
textTransform
:
'
none
'
,
textTransform
:
'
none
'
,
},
},
listItem
:
{
listItem
:
{
...
...
This diff is collapsed.
Click to expand it.
src/locales/en/translation.json
+
1
−
1
View file @
9d65d2a1
...
@@ -70,7 +70,7 @@
...
@@ -70,7 +70,7 @@
"mirador"
:
"Mirador"
,
"mirador"
:
"Mirador"
,
"miradorResources"
:
"Mirador resources"
,
"miradorResources"
:
"Mirador resources"
,
"miradorViewer"
:
"Mirador viewer"
,
"miradorViewer"
:
"Mirador viewer"
,
"more"
:
"
M
ore..."
,
"more"
:
"
m
ore..."
,
"moreResults"
:
"More results"
,
"moreResults"
:
"More results"
,
"mosaic"
:
"Mosaic"
,
"mosaic"
:
"Mosaic"
,
"mosaicDescription"
:
"Move and size windows in relation to each other, within the visible frame."
,
"mosaicDescription"
:
"Move and size windows in relation to each other, within the visible frame."
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment