Commit Graph

173 Commits

Author SHA1 Message Date
Aaron Jensen
9aca899376 hgweb: adding branch, tags, bookmarks, user, and file list to rss feed entries 2014-04-16 09:32:04 -07:00
Aaron Jensen
294492a1d9 hgweb: adding branch, tags, bookmarks, user, and file list to atom feed entries 2014-04-16 09:31:37 -07:00
Wei, Elson
9d83254247 hgweb: override the charset attribute in the http request
The default http request character set is UTF-8. If the message is not encoded
in UTF-8, such as big5, it cannot be shown correctly. The 'charset' is
overridden by the root document's, such that the user can select the proper
encoding in the browser.
2014-04-10 15:12:12 +08:00
anuraggoel
2e25e2e790 paper: overlapping of section title on help pages (issue4051)
Now there will be no overlap lines between various section title
on help pages. http://selenic.com/repo/hg/help/config
2014-03-03 23:37:59 +05:30
anuraggoel
d215557c0e coal: hgweb style adds extra blank line in file view (issue4136)
Now hgweb style='coal' adds no extra blank in file view.
2014-02-27 22:56:42 +05:30
Takumi IINO
22fc622e5e hgweb: infinite scroll support for coal style 2014-01-08 00:47:45 +09:00
Takumi IINO
95ecbefdae hgweb: infinite scroll support for monoblue style 2014-01-08 00:47:44 +09:00
Takumi IINO
e51fef56f2 hgweb: infinite scroll support for gitweb style 2014-01-08 00:47:43 +09:00
Takumi IINO
db72b3b5e8 hgweb: avoid invalid infinity scroll request when overwritten web.style
Infinity scroll is broken when you override the web.style in the following ways:

    $ hg --config='web.style=gitweb' serve
    $ open http://localhost:8080/shortlog?style=paper

ajaxScrollInit should use http://localhost:8080/shortlog/%next%?style=paper.
however, http://localhost:8080/shortlog/%next% is used actually.
It is missing style parameter.

This patch add style parameter to request url.
2014-01-08 00:35:03 +09:00
Takumi IINO
96e1c44734 hgweb: fix regexp for other styles like monoblue
Some styles have indentation.
2014-01-08 00:26:55 +09:00
Matt Mackall
c9a233d77e templater: fix escaping in nested string literals (issue4102)
Before the templater got extended for nested expressions, it made
sense to decode string escapes across the whole string. Now we do it
on a piece by piece basis.
2013-11-18 14:02:26 -05:00
Takumi IINO
56ac953b3c hgweb: add missing semicolon 2013-10-24 21:37:13 +09:00
Alexander Plavin
836ffef4a8 hgweb: fix unstoppable loading of graph when no more results
When a user reaches the end of repo history with graph view, it (unsuccessfully)
tried to load more entries. This patch disables further loading attempts.
2013-10-12 11:29:28 +04:00
Alexander Plavin
06d5dbdf36 hgweb: replace 'shortlog' with 'changelog' in raw changelog template 2013-08-16 21:41:19 +04:00
Alexander Plavin
099a1df11b hgweb: call process_dates with a specified selector in ajax scroll
Now this function processes only newly added entries, and not old ones,
the amount of which can be much bigger.
2013-09-06 13:30:58 +04:00
Alexander Plavin
6ef3f6fe6f hgweb: add parentSelector argument to process_dates
Allow specifying parent selector of elements to process, useful for
incremental page updates.
2013-09-06 13:30:58 +04:00
Alexander Plavin
3fd64dca8e hgweb: optimize process_dates function
This function looped over every node due to getElementsByTagName('*'), instead
of using selectors. In this patch we use querySelectorAll('.age') and process
only these nodes, which is much faster and also doesn't require extra condition.

Browser compatibility isn't sacrificed: IE 8+, FF 3.5+, Opera 10+.
2013-09-06 13:30:58 +04:00
Alexander Plavin
0502c7c0ba hgweb: eliminate extra complexity in process_dates definition
There was an extra anonymous outer function, called immediately. It is removed
in this patch.
2013-09-06 13:30:58 +04:00
Alexander Plavin
8495f525a8 paper: edit search hint to include new feature description 2013-09-06 13:30:57 +04:00
Alexander Plavin
e94f8da7af paper: define searchhint message in map file and use it in other templates 2013-07-25 01:12:25 +04:00
Alexander Plavin
7837b6944a paper: add infinite scrolling to graph by calling ajaxScrollInit at the page 2013-09-22 14:19:57 +04:00
Alexander Plavin
9bfb8fe898 hgweb: add graph mode of ajax response processing
While the default mode appends all the new entries to a container on the page,
the graph mode resizes canvas correctly, and repaints the graph to include
newly received data.
2013-09-20 00:42:13 +04:00
Alexander Plavin
f0c93d06c2 hgweb: make infinite scroll handling more generic and extensible
Namely, this allows the next page pointer to be not only revision hash given
in page code, but also any value computed from the value for previous page.
2013-09-22 14:18:23 +04:00
Alexander Plavin
ee2943c680 hgweb: add reset javascript function to Graph
It makes the Graph object to be in the same state as just after
the initialization. This will help to add infinite scrolling to graph view.
2013-09-06 13:30:59 +04:00
Alexander Plavin
e2c135afa3 hgweb: add link to force literal keyword search
This makes it possible to make keyword search in case the search query also
specifies an exact revision (like '1234' or 'abcdef'), or a revset expression.
2013-09-06 13:30:56 +04:00
Alexander Plavin
ce8b9c14cd raw: show current search mode name at search results 2013-09-06 13:30:56 +04:00
Alexander Plavin
d89a2b2e2e paper: show current search mode name at search results 2013-09-06 13:30:56 +04:00
Alexander Plavin
50e5b58d11 paper: add reddish background to ajax error message 2013-09-06 13:30:58 +04:00
Alexander Plavin
9b7f2aaba4 paper: add simple animation to the loading indicator 2013-09-06 13:30:58 +04:00
Alexander Plavin
9e2716e461 hgweb: add CSS class to the last entry on a page
The entry which was last before an ajax load now has a specific CSS class
for easier styling.
2013-09-06 13:30:58 +04:00
Alexander Plavin
29bb643339 hgweb: show message when an error occured during ajax loading 2013-09-06 13:30:58 +04:00
Alexander Plavin
6557099843 hgweb: show loading indicator while an ajax request is in process 2013-09-06 13:30:58 +04:00
Alexander Plavin
31f9685911 hgweb: show a message when there are no more entries in the list 2013-09-06 13:30:58 +04:00
Alexander Plavin
fb413116b4 paper: call ajaxScrollInit in shortlog
This just calls ajaxScrollInit at the shortlog page template with all needed
agruments. So, infinite scrolling is working now there.
2013-09-06 13:30:57 +04:00
Alexander Plavin
079f3668b4 hgweb: add ajaxScrollInit function, which does the ajax requests and processing
This function should be correctly called on a page, otherwise there is
no effect.
When called, it makes ajax requests for the next portion of changesets when the
user scrolls to the end. Also, when the monitor is high so that the
default amount of changesets isn't enough to fill it, multiple portions are
loaded if needed after the page load.
2013-09-18 22:44:12 +04:00
Alexander Plavin
e340f5be55 hgweb: add appendFormatHTML javascript function
This is a convenient helper function to append some formatted HTML markup to a
DOM element.
2013-09-06 13:30:58 +04:00
Alexander Plavin
3b1957de7e hgweb: add removeByClassName javascript function
It removes all elements with specified class name from the document.
2013-09-06 13:30:58 +04:00
Alexander Plavin
48ee1c4c4f hgweb: add docFromHTML javascript function
It takes a string with HTML markup and creates DOM document from it.
The implementation is a part of code from
https://developer.mozilla.org/en-US/docs/Web/API/DOMParser#DOMParser_HTML_extension_for_other_browsers
2013-09-06 13:30:57 +04:00
Alexander Plavin
6bdbb6b69d hgweb: add makeRequest javascript function
This function performs an asynchronous HTTP request and calls provided
callbacks:
- onstart: request is sent
- onsuccess: response is received
- onerror: some error occured
- oncomplete: response is fully processed and all other callbacks finished
2013-09-06 13:30:57 +04:00
Alexander Plavin
1dc1ac5d6a hgweb: add format javascript function
It replaces placeholders like '%key%' with replacement values given.
2013-09-06 13:30:57 +04:00
Alexander Plavin
9e521b740d paper: remove unused occurence of changelogtag in views
This variably isn't passed to these views and it always renders to empty string
for this reason. Other themes don't have this issue.
2013-08-03 00:34:56 +04:00
Alexander Plavin
ce27765c65 hgweb: show full date in rfc822 format in tooltips at shortlog page
The absolute date was not shown anywhere in the log view for users with
enabled JavaScript.
2013-06-30 11:48:21 +04:00
Kevin Bullock
a111856fd9 hgweb: remove trailing whitespace in mercurial.js 2013-08-04 16:19:12 -05:00
Alexander Plavin
db303d2e5c paper: get rid of changelogtag template duplication 2013-07-22 17:07:19 +04:00
Alexander Plavin
da7dc49074 paper: fix rendering of the first tab in a line in Webkit (issue3990)
This fixes issue3990 for Webkit-browsers, and also older Opera versions.
Rendering in firefox is not changed.
2013-07-21 18:50:54 +04:00
Alexander Plavin
793ff2d3f8 hgweb: highlight line which is linked to at annotate view 2013-07-14 05:35:04 +04:00
Alexander Plavin
76b5c57277 hgweb: highlight line which is linked to at comparison view 2013-07-13 17:32:54 +04:00
Alexander Plavin
2a275ba3af hgweb: change highlighted line color to be different from 'inserted' color
This changes line highlight color from a fain yellow (#ffff99) to
a faint blue (#bfdfff), because yellow color is used in comparison view for
inserted lines.
This new color is okay for people with different forms of color blindness
(tested with a simulator):
a) this color looks quite different from other used backgrounds
b) text doesn't lose distinction on this color
2013-07-13 17:31:53 +04:00
Alexander Plavin
af42bd5158 hgweb: make stripes in diffstat with CSS 2013-07-13 18:06:57 +04:00
Alexander Plavin
c077a7b985 hgweb: make stripes in file log with CSS 2013-07-13 18:03:35 +04:00