Skip to content

Commit

Permalink
Applies fixes for Doc Parser. (enso-org/ide#1098)
Browse files Browse the repository at this point in the history
Original commit: enso-org/ide@4f82dcf
  • Loading branch information
BinarySoftware authored Feb 11, 2021
1 parent 3fe3f51 commit c2ff91d
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 7 deletions.
5 changes: 4 additions & 1 deletion ide/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ read the notes of the `Enso 2.0.0-alpha.1` release.
now on all supported platforms.
- [You can now see data frames in the table visualisation][1181]. Big tables get truncated to 2000
entries.
- [Documentation in Searcher][1098]. Fixed cases where text would be misinterpreted as tag, added
support for new tag types, added support for more common characters, properly renders overflowing
text.

#### EnsoGL
- New multi-camera management system, allowing the same shape systems be rendered on different
Expand All @@ -37,12 +40,12 @@ read the notes of the `Enso 2.0.0-alpha.1` release.
to another and switched back to see the effect.

[1096]: https://github.com/enso-org/ide/pull/1172
[1098]: https://github.com/enso-org/ide/pull/1098
[1181]: https://github.com/enso-org/ide/pull/1181
[1190]: https://github.com/enso-org/ide/pull/1190
<br/>



# Enso 2.0.0-alpha.1 (2020-01-26)
This is the first release of Enso, a general-purpose programming language and environment for
interactive data processing. It is a tool that spans the entire stack, going from high-level
Expand Down
2 changes: 1 addition & 1 deletion ide/src/rust/ide/lib/parser/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ const PARSER_PATH: &str = "./pkg/scala-parser.js";
/// Commit from `enso` repository that will be used to obtain parser from.
/// FIXME: Using commit not from Engine's main branch but from a backported branch as the AST in
/// this project hasn't been updated to conform to latest scala parser (#732).
const PARSER_COMMIT: &str = "9d848fc59bfbab8aa202da71dc899759817dff0f";
const PARSER_COMMIT: &str = "a8e5c3e0f44e1a5049866d7151b1822f1665b486";

/// Magic code that needs to be prepended to ScalaJS generated parser due to:
/// https://github.com/scala-js/scala-js/issues/3677/
Expand Down
6 changes: 2 additions & 4 deletions ide/src/rust/ide/view/src/documentation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -142,10 +142,8 @@ impl Model {
Ok(PLACEHOLDER_STR.into())
} else {
let parser = parser::DocParser::new()?;
// FIXME [MM]: Removes characters that are not supported by Doc Parser yet.
// https://github.com/enso-org/enso/issues/1063
let processed = string.replace("\\n", "\n").replace("\"", "");
let output = match input_type {
let processed = string.to_string();
let output = match input_type {
InputFormat::AST => parser.generate_html_docs(processed),
InputFormat::Docstring => parser.generate_html_doc_pure(processed),
};
Expand Down
20 changes: 19 additions & 1 deletion ide/src/rust/ide/view/src/documentation/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@
color: #333333;
margin: 0;
padding: 0;
width: 100%;
overflow-wrap: break-word;
}

.dark-theme .docVis {
Expand Down Expand Up @@ -172,6 +174,10 @@
.Tags .ADDED,
.Tags .UPCOMING,
.Tags .REMOVED,
.Tags .PRIVATE,
.Tags .ADVANCED,
.Tags .TEXT_ONLY,
.Tags .UNSTABLE,
.Tags .UNRECOGNIZED {
line-height: 1.5;
font-weight: 400;
Expand All @@ -198,6 +204,10 @@
}
.Tags .UPCOMING,
.Tags .REMOVED,
.Tags .PRIVATE,
.Tags .ADVANCED,
.Tags .TEXT_ONLY,
.Tags .UNSTABLE,
.Tags .UNRECOGNIZED {
border: 1px solid #32302E;
color: #32302E;
Expand All @@ -213,6 +223,10 @@
.dark-theme .Tags .UNRECOGNIZED,
.dark-theme .Tags .DEPRECATED,
.dark-theme .Tags .MODIFIED,
.dark-theme .Tags .PRIVATE,
.dark-theme .Tags .ADVANCED,
.dark-theme .Tags .TEXT_ONLY,
.dark-theme .Tags .UNSTABLE,
.dark-theme .Tags .ADDED{
font-weight: 500;
background-color: #42403e;
Expand All @@ -232,8 +246,12 @@
color: rgb(15.32% 51.59% 84.81%);
}
.dark-theme .Tags .REMOVED {
color: rgb(80.24% 34.06% 37.72%);
color: rgb(80.24% 34.06% 37.72%);
}
.dark-theme .Tags .PRIVATE,
.dark-theme .Tags .ADVANCED,
.dark-theme .Tags .TEXT_ONLY,
.dark-theme .Tags .UNSTABLE,
.dark-theme .Tags .UNRECOGNIZED {
color: #fafafa;
}
Expand Down

0 comments on commit c2ff91d

Please sign in to comment.