SHA256
1
0
This commit is contained in:
Alex Wied
2026-06-09 15:40:28 -04:00
parent d0dc1b277d
commit a5f62602f6
7 changed files with 751 additions and 109 deletions
+5 -5
View File
@@ -1,5 +1,5 @@
use crate::rdf::ontology;
use crate::rdf::ontology::Ontology;
use crate::rdf::vocab::{gl, rda};
use crate::rdf::term_helper::{TermHelper, TermHelperMut};
use gl_search::{doc, Schema, SearchDocument, SearchIndex};
use http::StatusCode;
@@ -657,7 +657,7 @@ impl Publisher {
let search_input =
text_input("Query", &search_state.query).on_input(Message::QueryUpdated);
let label_column = table::column("Label", |result: &NamedNode| {
let type_column = table::column("Type", |result: &NamedNode| {
let label = self.ontology.label(result.as_ref()).unwrap_or("Unknown");
button(text(label))
@@ -670,7 +670,7 @@ impl Publisher {
.style(button::text)
});
let results_table =
scrollable(table([label_column, iri_column], &search_state.results));
scrollable(table([type_column, iri_column], &search_state.results));
return column![search_input, results_table].into();
}
@@ -693,8 +693,8 @@ impl Publisher {
let body: Element<Message> = if self.show_new_document_buttons {
column![
self.view_new_entity_buttons(self.ontology.subclass_of(ontology::GL_ENTITY)),
self.view_new_entity_buttons(self.ontology.subclass_of(ontology::RDA_ENTITY)),
self.view_new_entity_buttons(self.ontology.subclass_of(gl::ENTITY)),
self.view_new_entity_buttons(self.ontology.subclass_of(rda::ENTITY)),
]
.into()
} else {