Compare commits

...

5 commits
0.9.4 ... main

Author SHA1 Message Date
Morgan McMillian 31424205e9 prep for release of 0.9.5 2020-02-16 07:33:22 -08:00
Morgan McMillian 8c1d527068 fix html parsing of user profile description, issue #56 2020-02-05 22:37:32 -08:00
Morgan McMillian bd441eac0e Refresh post when repost (or remove repost) is performed, issue #57 2020-02-05 22:01:49 -08:00
Morgan McMillian 14e536947b Scope & rewrite in links to what is actually contained in the href 2020-02-05 22:00:52 -08:00
Morgan McMillian c1bbb23daf rewrite & as & so that links will render properly, issue #54 2020-02-02 07:26:42 -08:00
7 changed files with 33 additions and 4 deletions

View file

@ -3,6 +3,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
## [0.9.5] - 2020-02-16
### Fixed
- Refresh post following a repost (issue #57)
- Fix HTML parsing on user descriptions (issue #56)
- Fix parsing of links containing & (issue #54)
## [0.9.4] - 2020-02-01
### Fixed
- Updated longpost url (issue #53)
@ -106,6 +112,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
### Added
- Initial release
[0.9.5]: https://gitlab.dreamfall.space/thrrgilag/goober-bb10/-/tags/0.9.5
[0.9.4]: https://gitlab.dreamfall.space/thrrgilag/goober-bb10/-/tags/0.9.4
[0.9.3]: https://gitlab.dreamfall.space/thrrgilag/goober-bb10/-/tags/0.9.3
[0.9.2]: https://gitlab.dreamfall.space/thrrgilag/goober-bb10/-/tags/0.9.2

View file

@ -1,5 +1,6 @@
import bb.cascades 1.4
import com.netimage 1.0
import "parser.js" as Parser
Container {
id: useritem
@ -54,7 +55,7 @@ Container {
Container {
Label {
id: description
text: ListItemData.content.html
text: Parser.fixPostHtml(ListItemData.content.html)
multiline: true
textFormat: TextFormat.Html
}

View file

@ -20,5 +20,11 @@
function fixPostHtml(data) {
data = data.replace(/<\\?\/?span[^>]*>/g, "");
data = data.replace(/<br>/g, "<br/>");
var hrefreg = /<a\shref=\\?"([^>]*)\\?">/;
var hrefm = hrefreg.exec(data);
if (hrefm != null) {
var href = hrefm[1].replace(/&/g, "&amp;");
data = data.replace(hrefreg, "<a href=\"" + href + "\">");
}
return data;
}

View file

@ -56,7 +56,7 @@
<!-- A string value of the format <0-999>.<0-999>.<0-999> that represents application version which can be used to check for application upgrade.
Values can also be 1-part or 2-part. It is not necessary to have a 3-part value.
An updated version of application must have a versionNumber value higher than the previous version. Required. -->
<versionNumber>0.9.4</versionNumber>
<versionNumber>0.9.5</versionNumber>
<!-- Fourth digit segment of the package version. First three segments are taken from the
<versionNumber> element. Must be an integer from 0 to 2^16-1 -->

View file

@ -149,6 +149,9 @@ lupdate_inclusion {
$$quote($$BASEDIR/../src/*.cc) \
$$quote($$BASEDIR/../src/*.cpp) \
$$quote($$BASEDIR/../src/*.cxx) \
$$quote($$BASEDIR/..//*.qml) \
$$quote($$BASEDIR/..//*.js) \
$$quote($$BASEDIR/..//*.qs) \
$$quote($$BASEDIR/../assets/*.qml) \
$$quote($$BASEDIR/../assets/*.js) \
$$quote($$BASEDIR/../assets/*.qs) \

View file

@ -305,6 +305,12 @@ void Pnut::onAuthorizedRequestReady(QByteArray data, int id)
req_map.remove(id);
getPost(variant.toMap()["data"].toMap()["id"].toString());
}
else if (endpoint.startsWith(":repost"))
{
qDebug() << "Repost successful!";
req_map.remove(id);
getPost(variant.toMap()["data"].toMap()["id"].toString());
}
else
{
qDebug() << "GOT SOMETHING NEW!";
@ -319,6 +325,12 @@ void Pnut::onAuthorizedRequestReady(QByteArray data, int id)
qDebug() << "Create post success!";
req_map.remove(id);
}
else if (endpoint.startsWith(":repost"))
{
qDebug() << "Repost successful!";
req_map.remove(id);
getPost(variant.toMap()["data"].toMap()["id"].toString());
}
else
{
qDebug() << "Good but not sure what";

View file

@ -256,12 +256,12 @@
<context>
<name>UserItem</name>
<message>
<location filename="../assets/UserItem.qml" line="67"/>
<location filename="../assets/UserItem.qml" line="68"/>
<source>Unfollow</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../assets/UserItem.qml" line="67"/>
<location filename="../assets/UserItem.qml" line="68"/>
<source>Follow</source>
<translation type="unfinished"></translation>
</message>