|
@@ -2599,18 +2599,8 @@ holding contextual information."
|
|
|
(full-text (funcall (plist-get info :html-format-headline-function)
|
|
|
todo todo-type priority text tags info))
|
|
|
(contents (or contents ""))
|
|
|
- (ids (delq nil
|
|
|
- (list (org-element-property :CUSTOM_ID headline)
|
|
|
- (org-export-get-reference headline info)
|
|
|
- (org-element-property :ID headline))))
|
|
|
- (preferred-id (car ids))
|
|
|
- (extra-ids
|
|
|
- (mapconcat
|
|
|
- (lambda (id)
|
|
|
- (org-html--anchor
|
|
|
- (if (org-uuidgen-p id) (concat "ID-" id) id)
|
|
|
- nil nil info))
|
|
|
- (cdr ids) "")))
|
|
|
+ (id (or (org-element-property :CUSTOM_ID headline)
|
|
|
+ (org-export-get-reference headline info))))
|
|
|
(if (org-export-low-level-p headline info)
|
|
|
;; This is a deep sub-tree: export it as a list item.
|
|
|
(let* ((html-type (if numberedp "ol" "ul")))
|
|
@@ -2619,11 +2609,9 @@ holding contextual information."
|
|
|
(apply #'format "<%s class=\"org-%s\">\n"
|
|
|
(make-list 2 html-type)))
|
|
|
(org-html-format-list-item
|
|
|
- contents (if numberedp 'ordered 'unordered)
|
|
|
- nil info nil
|
|
|
- (concat (org-html--anchor preferred-id nil nil info)
|
|
|
- extra-ids
|
|
|
- full-text)) "\n"
|
|
|
+ contents (if numberedp 'ordered 'unordered)
|
|
|
+ nil info nil
|
|
|
+ (concat (org-html--anchor id nil nil info) full-text)) "\n"
|
|
|
(and (org-export-last-sibling-p headline info)
|
|
|
(format "</%s>\n" html-type))))
|
|
|
;; Standard headline. Export it as a section.
|
|
@@ -2636,10 +2624,9 @@ holding contextual information."
|
|
|
(concat (format "outline-%d" level)
|
|
|
(and extra-class " ")
|
|
|
extra-class)
|
|
|
- (format "\n<h%d id=\"%s\">%s%s</h%d>\n"
|
|
|
+ (format "\n<h%d id=\"%s\">%s</h%d>\n"
|
|
|
level
|
|
|
- preferred-id
|
|
|
- extra-ids
|
|
|
+ id
|
|
|
(concat
|
|
|
(and numberedp
|
|
|
(format
|
|
@@ -3010,16 +2997,11 @@ INFO is a plist holding contextual information. See
|
|
|
;; relative to a custom-id, a headline title, a name or
|
|
|
;; a target.
|
|
|
(let ((option (org-element-property :search-option link)))
|
|
|
- (cond ((not option) raw-path)
|
|
|
- ;; Since HTML back-end use custom-id value as-is,
|
|
|
- ;; resolving is them is trivial.
|
|
|
- ((eq (string-to-char option) ?#) (concat raw-path option))
|
|
|
- (t
|
|
|
- (concat raw-path
|
|
|
- "#"
|
|
|
- (org-publish-resolve-external-link
|
|
|
- option
|
|
|
- (org-element-property :path link)))))))
|
|
|
+ (if (not option) raw-path
|
|
|
+ (let ((path (org-element-property :path link)))
|
|
|
+ (concat raw-path
|
|
|
+ "#"
|
|
|
+ (org-publish-resolve-external-link option path t))))))
|
|
|
(t raw-path)))
|
|
|
;; Extract attributes from parent's paragraph. HACK: Only do
|
|
|
;; this for the first link in parent (inner image link for
|