Inline XBRL Part 0: Primer 1.1

Supporting document for a Draft Public Working Draft 31 May 2013

Copyright © 2010, 2011, 2013 XBRL International Inc., All Rights Reserved.

This version:
inlineXBRL-part0-DPWD-2013-05-31.html
Editor:
Philip Allen, CoreFiling Limited <plega@corefiling.com>

Status

Circulation of this supporting document for a Draft Public Working Draft is restricted to participants in XBRL International and is not appropriate to cite from other sources. Other documents may supersede this document. Recipients are invited to submit comments to rendering-feedback@xbrl.org, and to submit notification of any relevant patent rights of which they are aware and provide supporting documentation.

Abstract

Inline XBRL Part 0: Primer is a non-normative document intended to provide an easily readable description of Inline XBRL. [Inline XBRL Specification] and [Inline XBRL Schema] provide the complete normative description of the Inline XBRL specification.

Table of Contents

1 Introduction
1.1 Purpose and functionality
1.2 About version 1.1
2 Structure
2.1 The Inline XBRL Document
2.2 Multiple documents
2.3 Target documents
2.4 Use of ID types
3 Processing and validation
3.1 Inline XBRL documents
3.2 Processors
3.2.1 The Conformant Processor
3.2.2 The Validating Conformant Processor
3.3 Validation
3.4 Conformance suite
3.4.1 Use of valid test pairs in the conformance suite
3.4.2 Use of invalid IXDSs in the conformance suite
3.5 Identification of Inline XBRL documents
3.5.1 Doctype
3.5.2 Meta tags
3.5.3 Version
3.5.4 Namespace
3.5.5 Processing Inline XBRL
3.5.6 Non-XHTML
4 Transformations
4.1 Transformation Rules
4.2 Transformation Rules Registries
4.3 The Specified Registry
5 Mapping values to the Target Document
5.1 Contexts
5.2 Duplicates
5.3 Equal values
5.4 Footnotes and explanatory facts
5.5 Totalling
5.6 Nested non-numeric tags
5.7 Nested numeric tags
5.8 Nested tuples
5.9 Signs
5.10 Other attributes
5.11 xml:lang
6 Formatting
6.1 Markup elements in text data
6.1.1 ix:continuation
6.2 XLink support
6.3 XML-escaping
7 Syntax
7.1 MIME types
7.2 Namespace declarations
7.3 Page breaks
7.4 QNames in attributes
7.5 URIs in Markup elements
7.6 URIs in Inline XBRL Elements
8 Discussion of consuming applications
8.1 Hidden elements
8.2 DOM

Appendices

A References
B Intellectual property status (non-normative)
C Acknowledgements (non-normative)
D Document history (non-normative)
E Errata corrections in this document


1 Introduction

Inline XBRL was created to avoid the need to create visual renderings of XBRL instance documents.

Conventional XML data documents (like XBRL instance documents) maintain a separation of data and rendering instructions. The data is kept in the XML data document, and the rendering instructions are kept in a stylesheet or separate application. Where the structure of the data is known in advance, this is efficient and simple. XBRL, however, is based on taxonomies and not schemas: the precise data content of a document is often not known in advance. This makes it difficult to devise satisfactory rendering instructions.

Inline XBRL is a mechanism for allowing the author of the XBRL instance document to specify the visual rendering of the data. It does this by providing a method for incorporating XBRL instance data and metadata into an HTML or XHTML document. The [Inline XBRL Specification] defines how this data and metadata can then be used to construct an XBRL instance document.

1.1 Purpose and functionality

It should be understood that the purpose of Inline XBRL is to encapsulate data and metadata within host documents so that it may be extracted into XBRL instance documents and thereafter handled as conventional XBRL. It follows, therefore, that the present Specification has two functions:

  1. to define the content of an Inline XBRL Document Set, which under certain circumstances can be validated as such; and
  2. to define a single set of rules for the extraction of data from an Inline XBRL Document Set into one or more XBRL-valid XBRL instance documents.

1.2 About version 1.1

Version 1.1 is the second release of the Specification for Inline XBRL. This version adds to version 1.0 a mechanism, ix:continuation, for splitting text content within a document, in addition to the existing mechanism which uses ix:exclude. It also allows the nesting of ix:nonFraction and ix:fraction; and it replaces the linking mechanism for footnote resources with a structure based on a new element, ix:relationship, which also provides support for fact-explanatoryFact links.

2 Structure

2.1 The Inline XBRL Document

The Inline XBRL Document is typically a single XHTML document which, when displayed in a browser, provides a full visual rendering of given XBRL data. An Inline XBRL processor (a "Processor"), given that Inline XBRL Document, will generate an XBRL instance document.

In the Inline XBRL Document, data values are nested within Inline XBRL Elements which are themselves nested within HTML or XHTML elements ("Markup Elements"). This technique relies upon the ability of browsers to ignore XML elements that it does not recognise. The browser, in effect, ignores the Inline XBRL Elements and displays the data values as though they were textual content of the Markup Elements. A Processor will ignore the Markup Elements and combine the Inline XBRL Elements and the data values to generate an XBRL instance document (the "Target Document").

2.2 Multiple documents

Current browsers impose an effective maximum size limit on the files that they can handle. The financial statements for a large company, which might be in the order of five megabytes in size, are too large for most browsers to handle today.

To get round this limitation, a complete set of Inline XBRL information can be split across multiple documents. The [Inline XBRL Specification] allows a set of documents, which together may form part of a web-site, to be treated as a single Inline XBRL Document Set ("IXDS"). There are few restrictions relating to the division of metadata between the different documents in the document set, so it is open to the author to repeat metadata across documents or to abstract common metadata (such as context information) into a header document.

When constructing multiple documents, be careful to use relative URLs in hyperlinks between the documents, so that they don't break when moved to other environments.

The [Inline XBRL Specification] allows (although it does NOT recommend) the IXDS to consist of both HTML and XHTML documents. The [Inline XBRL Specification] requires that a Validating Conformant Processor validate any XHTML documents against the Schema, but it will not validate or process a mixed-type IXDS.

2.3 Target documents

Inline XBRL allows more than one Target Document to be created from the Inline XBRL Document, so as to make it possible to take two (or more) separate XBRL reports and display the data in a single web page. This allows the author to build an HTML page which combines comparative data from different companies which, when processed, would become a set of financial reports, one for each company.

But it is important not to confuse the mechanism for multiple input documents (i.e., the IXDS) with that for multiple output documents (i.e. Target Documents). It was never the intention that the multiple documents in the IXDS would map into multiple Target Documents, although it is possible to construct an IXDS in this way. Any two random Inline XBRL Documents - which, when processed would create individual Target Documents - will often not be suitable to be treated as constituent parts of the same IXDS, because of the need to ensure that IDs and references are unique across the IXDS, and that the target attributes are set appropriately.

Each Inline XBRL Element is mapped to a given Target Document. The Target Document is identified logically (but not physically) by means of the "target" attribute (if any) on that Inline XBRL Element. If there is no target attribute then the Inline XBRL Element will map to the "default" Target Document.

There is no distinction, other than the convenience of the specification, between specified Target Documents and the default Target Document. It follows that, if there are no target attributes, there will be only one Target Document and that will be the default Target Document. On the other hand, if target attributes are set on all the appropriate Inline XBRL Elements, there will be no default Target Document, and if the value of all those target attributes is the same then there will be only one Target Document.

It follows that, if the target attribute is never specified in the IXDS, all output will be mapped to the same, single, Target Document. If target attributes are provided in some cases but not in others there will always be at least two Target Documents produced.

It also follows that an individual element will normally not be mapped to more than one Target Document. The exception to this is where a footnote is referenced by XBRL facts with different target attributes, where the footnote will be mapped to all the relevant Target Documents. A similar situation arises where an XBRL fact is used in place of the footnote, although here the referenced fact may also have its own target attribute, which will also be mapped in its own right and not just as the product of a relationship.

2.4 Use of ID types

Because Inline XBRL can use multiple documents, use of IDs and IDREFs is scoped across the IXDS rather than the individual Inline XBRL Document. Thus, an item of type IDREF must have a matching ID somewhere within the IXDS, not necessarily within the same Inline XBRL Document. However, the conventional method of IDREF typing (as defined in [XML Schema Datatypes]) can only be applied, for validation purposes, to a single document.

We considered requiring that schema validation be applied to an IXDS that had been merged to create a single document. However, while the Inline XBRL Elements in the IXDS can be merged without danger to the semantics, the Markup Elements cannot. There are issues relating to merging common elements - like HTML, HEAD and BODY - which would make it difficult to validate the document with confidence after the merge.

The problem is that schema validation using the XHTML Modular Schema covers both the Inline XBRL elements and the Markup Elements. Given that the merge can have unpredictable results on the validity of the XHTML, it is sensible to restrict schema-level validation to each individual Inline XBRL Document rather than the IXDS.

We have accordingly avoided IDREF and IDREFS types in the [Inline XBRL Schema], making use of xs:NCName types instead, replacing the implicit schema constraints with appropriate MUSTs within the [Inline XBRL Specification]. These MUSTs are then tested by proprietary code within the Validating Conformant Processor, which can do so without concern about the impact of merging on XHTML validation.

We have taken the same approach with the optional id attribute, which uses the xs:NCName type, and is required by the [Inline XBRL Specification] to be unique across the IXDS. By requiring id attributes to be unique across the IXDS it becomes simpler for the Processor to identify elements, should that be necessary.

Authors should therefore be aware that contextRef, id, tupleID, tupleRef and unitRef attributes are validated with reference to the IXDS and not the individual Inline XBRL Document.

3 Processing and validation

3.1 Inline XBRL documents

The [Inline XBRL Specification] provides for different levels of conforming Inline XBRL documents. Inline XBRL documents will generally be HTML or XHTML. They can also, in theory, be any other well-formed XML dialect. All must, of course, be compliant with the specification but only XHTML documents can be validated using the normative [Inline XBRL Schema].

The following table summarises the validation framework for Inline XBRL documents. It is described in fuller detail in the following paragraphs.

Non-HTML HTML XHTML
Well-formed XML and compliant Inline XBRL MUST MUST MUST
Validatable against [Inline XBRL Schema] no no yes
Validatable by a Validating Conformant Processor against the rules set out in the [Inline XBRL Specification] MUST NOT MUST NOT MUST

It is worth noting that HTML documents are not often well-formed, and that most authoring tools may have more success creating XHTML than well-formed HTML. We would strongly recommend the use of XHTML rather than HTML. We expect that most Inline XBRL applications will in fact require XHTML.

The specification, however, does not outlaw non-XHTML dialects because we wanted to encourage as-yet unforeseen uses of Inline XBRL to develop in the future with the full benefit of the specification. There is, in fact, no technical reason short of validation why non-XHTML dialects should not be as acceptable a host for Inline XBRL as XHTML.

3.2 Processors

The purpose of the Processor is to generate XBRL from an IXDS without reference to any taxonomy. Even so, there are different types of Processors:

3.2.1 The Conformant Processor

The Conformant Processor must be able to handle multiple input documents (which together comprise the IXDS) and be able to generate multiple Target Documents.

3.2.2 The Validating Conformant Processor

The Validating Conformant Processor is required to validate the IXDS and may only validate an IXDS which consists solely of XHTML documents. If (and only if) the IXDS is valid, it will then generate the Target Document(s).

3.3 Validation

Validation is the process which must be carried out in full by a Validating Conformant Processor on any XHTML document. Validation involves:

  1. testing that the IXDS meets the rules set out in the [Inline XBRL Specification]; and
  2. validating each of the Inline XBRL Documents against the [Inline XBRL Schema].

For the purposes of the conformance suite, a set of Schematron rules have been created, which test many of the rules set out in the [Inline XBRL Specification]. Together, the Schematron rules and the Schema provide nearly-complete coverage of all the requirements of the [Inline XBRL Specification].

Note that while the rules in the [Inline XBRL Specification] and the [Inline XBRL Schema] are both normative (the latter only for XHTML-based documents), the Schematron rules are non-normative. This is because the Schematron rules are encapsulations of the (normative) MUSTs in the [Inline XBRL Specification], while the [Inline XBRL Schema] covers concepts which are not in all cases made explicit in the [Inline XBRL Specification].

The implication of this is that application of the Schematron rules will NOT necessarily meet the requirement for a Validating Conformant Processor to test that the IXDS meets the rules set out in the [Inline XBRL Specification].

The [Inline XBRL Schema] uses a modular technique which involves extending the XHTML Schema to accept Inline XBRL Elements within the XHTML document. The Schema also makes use of parts of the schemas for XBRL, but to accomplish this some changes have had to be made to the structure of the XBRL Schemas that are referenced by the modular [Inline XBRL Specification]. The re-structured schemas logically define identical instance document content models as the normative XBRL Schemas.

3.4 Conformance suite

The conformance suite is used to test a Processor and has no role in determining the validity of a given Inline XBRL Document.

3.4.1 Use of valid test pairs in the conformance suite

The conformance suite consists largely of pairs of IXDSs and Target Documents. Each pair is illustrative of a conforming transformation. Both a Conformant Processor and a Validating Conformant Processor will, when processing a given IXDS, generate the associated Target Documents; if it does not, it will not be deemed conformant.

3.4.2 Use of invalid IXDSs in the conformance suite

The conformance suite also includes IXDSs that are not valid, which are used only to test Validating Conformant Processors. A Validating Conformant Processor will, when processing an invalid IXDS, generate a failure message.

3.5 Identification of Inline XBRL documents

3.5.1 Doctype

Setting a DOCTYPE in the Inline XBRL Document will, in many processing situations, trigger an attempt to validate against a DTD. We did not plan for the use of DTDs in Inline XBRL because of lack of support for namespaces in DTDs. There is therefore no normative DTD for Inline XBRL.

We strongly advise against setting a DOCTYPE in Inline XBRL Documents, because it is liable to lead to a validation failure.

3.5.2 Meta tags

Under certain circumstances, Internet Explorer is known to handle rendering of Inline XBRL Documents incorrectly. In many cases this can be resolved by adding a meta tag to the document:

Add the tag <meta http-equiv="X-UA-Compatible" content="IE=7" /> or <meta http-equiv="X-UA-Compatible" content="IE=8" /> to the document to correct rendering problems with certain documents.

Note that this solution may not work for Internet Explorer 7.

3.5.3 Version

The version attribute can, optionally, be used to identify a document as Inline XBRL. If used, the value MUST be the Formal Public Identifier defined in [Inline XBRL Schema] (currently "-//XBRL International//DTD XHTML Inline XBRL 1.1//EN").

It is worth noting that the Public Text Class "DTD", when used as part of the Formal Public Identifier, means "document type declaration subset" and not "Document Type Definition"; so the use of the Formal Public Identifier should not be taken to imply the existence of a Document Type Definition.

3.5.4 Namespace

The Inline XBRL namespace name, http://www.xbrl.org/2008/inlineXBRL, identifies Inline XBRL elements with the 1.0 version of this standard (and all its errata corrections, if any). Any subsequent versions of this standard (i.e., non-errata correction changes which have an impact on validity) will have a new namespace name. The namespace name for the current version, 1.1, is http://www.xbrl.org/DPWD-2013-05-31/inlineXBRL.

We recommend using the namespace name to identify all Inline XBRL documents.

3.5.5 Processing Inline XBRL

Because the version attribute is optional, it cannot be relied upon by Processors seeking to identify a document as Inline XBRL. Instead, a Processor will look for (a) the namespace of the root HTML element, which should have the namespace name  http://www.w3.org/1999/xhtml; and (b) the existence of one or more elements which have the http://www.xbrl.org/DPWD-2013-05-31/inlineXBRL namespace name.

It will often be the case that the namespace name of the root element will have a schema location hint leading the Processor to http://www.xbrl.org/DPWD-2013-05-31/inlineXBRL/xhtml-inlinexbrl-1_0.xsd: but this location is not mandatory (and so cannot be relied upon) and will in any case (for security or performance considerations) often be ignored by the Processor.

The implication of using the Inline XBRL namespace name as a key identifier is that a Processor is not allowed to distinguish between the REC version of the specification and subsequent errata, if any. The Processor must support both REC and all the errata.

3.5.6 Non-XHTML

A document which does not have a root HTML element (or which has a root HTML element which does not have the namespace name "http://www.w3.org/1999/xhtml") but which does include one or more elements which have the "http://www.xbrl.org/DPWD-2013-05-31/inlineXBRL" namespace name can still be in full compliance with the Inline XBRL specification and therefore can be considered prima facie an Inline XBRL Document. A Conformant Processor is expected to process such a document successfully, if it is in compliance with the specification. However, a Validating Conformant Processor will not successfully validate such a document and is not allowed to process it further.

If the document complies with the specification the Processor will be able to generate the Target Document successfully. However, in the absence of validation there is no obvious way of determining compliance and the behaviour of the Processor in the presence of a non-compliant document is not defined by the specification. The purpose of this treatment is to allow well-formed XML (other than XHTML) to host Inline XBRL Elements. As mentioned above, had we forbidden any host markup other than XHTML it would have outlawed potential future uses of the Specification.

4 Transformations

4.1 Transformation Rules

The [Inline XBRL Specification] provides examples of Transformation Rules, but the normative list will be maintained separately. The transformations will require different implementations for different execution environments.

Transformation Rules may be thought of as parsing rules; they convert textual displays into XML Schema data types having canonical lexical representations along with XBRL specific attributes. Transformation Rules producing types derived from xs:decimal, in particular, must interpret the decimals and precision attributes and produce not only a canonical lexical representation but also corresponding decimals and precision attributes.

There is a long tail of potentially useful transformations to parse currency symbols, dates (in a variety of formats), Boolean values, texts written right-to-left, Chinese, and other display formats. The registry is a practical means for covering a large set of critical numeric and date types for browser execution, XSL and other key environments, while allowing for growth in the set of transformations and implementations.

4.2 Transformation Rules Registries

Transformation Rules are stored in a Transformation Rules Registry which may consist of multiple versions, over time. Within a registry a function is identified by its local name, with the presumption that the function assigned to that local name will never change. Functions will persist from one version of the registry to the next, and only be dropped from subsequent versions in the case of deprecation. This allows the creation of a set of Transformation Rules and their amendment over time while maintaining clarity as to content and purpose.

A given registry is identified by its namespace, which will incorporate the date that that version of the registry was accorded REC status. This neatly resolves the issue of errata corrections - because errata don't have a REC date they can't have a separate namespace and so must be identified with any reference to the underlying registry version.

For developers, the namespace mechanism provides both clarity as to the identification of the set of functions being supported, and a simple way to upgrade provision from one version of a registry to another.

4.3 The Specified Registry

The Specified Registry is the initial version of the registry defined by XBRL International and which is required to be supported by any processor which supports Inline XBRL. It should be noted that subsequent versions of that registry are not required to be supported, although we would expect that implementations of Inline XBRL will probably seek to do so.

It was intended by the authors of the specification that the Specified Registry would meet the needs of regulators and other users of Inline XBRL. The registry framework, as described above, nevertheless provides a clean mechanism for the creation and maintenance of other registries by third parties.

It should be noted that the namespace name given to the Specified Registry was changed when the specification was accorded REC status (so as to incorporate the REC date) and is therefore not the same namespace name as was published in the Proposed REC and previous versions of the specification.

5 Mapping values to the Target Document

Every XBRL fact and xlink relationship in the Target Document must be justified by reference to an appropriate Inline XBRL Element in the input data. This means that the Target Document is not allowed to contain other facts or relationships. (It does not, incidentally, prohibit duplication, if duplicates are present in the input data.) Nor does it restrict contexts and units, which may be included in the Target Document whether or not they appeared in the input document.

5.1 Contexts

Inline XBRL does not specify any way for the text content of Markup Elements displayed in a browser to be transformed into the content of contexts in the Target Documents. Dates appearing in column headings, for example, normally appear in the IXDS as Markup Elements without any Inline XBRL Element ancestors. Management of the contexts referenced by xbrli:contextRef attributes in the IXDS is done as in any other XBRL creation process.

5.2 Duplicates

Financial statements normally have at least a handful of facts that appear in more than one location in an IXDS. Net Income, for example, may appear both on an Income Statement and a Statement of Cash Flows. If both occurrences in the IXDS are tagged with the same element and context, and have the same actual or default {target} property, the output may contain both occurrences.

In some cases it will be desired that such occurrences ("duplicates") are removed from the output. However, the rules for de-duplication will vary from occasion to occasion. Duplicates as defined by the XBRL v2.1 Specification can only be determined by reference to the DTS. Because Processors are not required to access the DTS, it cannot be assumed that a Processor will be able to carry out XBRL-level de-duplication. In addition, because it is possible to add user-defined (non-Inline XBRL) attributes to Inline XBRL Elements, output elements which are XBRL-s-equal may actually contain different attribute-level information.

The [Inline XBRL Specification] therefore allows de-duplication to be carried out at the discretion of the Processor.

In some cases, either because of different rounding conventions or by mistake, a pair of facts may match as to element name, context and {target} property, but may have different values. The [Inline XBRL Specification]requires that both facts appear in the Target Document. This is not illegal XBRL but it is very much to be deplored.

Avoid including matching facts with different values in the IXDS.

In the case of tuple children, however, the creation of duplicates in the Target Document will often be schema-invalid. For this reason, duplicate tuple children are removed prior to mapping. To keep the Processor as light-weight as possible, duplicates for these purposes are defined as those with the same tuple order value. To validate that these two elements do indeed have the same value, a string-comparison mechanism is used. This is more restrictive than the XBRL v2.1 Specification, which allows (say) for two elements with the same value to use different schemaRef attributes. Such elements would fail Inline XBRL validation. We consider that the benefits of this restriction, by making it easier to process Inline XBRL, outweigh any drawbacks.

5.3 Equal values

An author might wish for a fragment of text in an IXDS to correspond to more than one fact in a Target Document. For example, a formatted date such as "25 June 2008" may need to appear in the Target Document both as a tuple with day, month and year, and separately as an item of type dateTime. Inline XBRL does not support a one-to-many mapping of source text to facts.

The correct way to handle "one to many" mappings is to tag the text with one of the mappings, and place the other output tag inside an ix:hidden element.

5.4 Footnotes and explanatory facts

Inline XBRL does not match the full XBRL footnote model. In an XBRL instance document, footnotes are connected to facts through an intermediate link, the footnoteLink element. This structure provides an extra level of indirection at the cost of being verbose and relatively difficult for the casual reader to understand. Experience since the publication of [XBRL 2.1] strongly suggests the benefits of this indirection have been rarely, if ever, realised.

For Inline XBRL, it was decided to simplify the footnote model by omitting much of XBRL's support for XLink, in order to make footnotes easier to use and thereby making this specification easier to understand.

For Inline XBRL v1.1 the reference model was extended to include the ability to reference other XBRL facts as well as footnote resources. The new reference model, which supports references to both footnotes and to XBRL facts, uses a single intermediary element, ix:relationship, to link to the reference from the calling element.

To maintain simplicity within the specification, the reference mechanism used in Inline XBRL v1.0 (use of footnoteRefs attributes on XBRL facts to point to ix:footnote elements) is no longer allowed.

Note that the mapping of both footnotes and explanatory facts is determined by the "calling" fact and are mapped to the same Target Document as the calling fact. Explanatory facts also have their own target attribute and so can also be mapped (in their own right) to another Target Document.

5.5 Totalling

A special case of "Equal values" would be a numeric value displayed in the Inline XBRL Document that is meant to map to more than one output fact, the sum of which is the displayed total. (Note that in some regulatory environments, this would clearly not be acceptable.) The displayed figure would have no Inline XBRL tags at all; the output facts would simply appear as Inline XBRL Elements inside the ix:hidden element.

5.6 Nested non-numeric tags

There is, however, a special case where "dual tagging" of a single piece of displayed text is permissible. Individual pieces of data which fall within an ix:nonNumeric tag may also themselves be tagged. So a textual note can be tagged as ix:nonNumeric and parts of the text (say, a fraction) can also be tagged (in this case, as ix:fraction). That fraction will appear twice in the Target Document, once as part of the textual note and once as a numeric fact.

A single date within ix:nonNumeric tags could, for instance, be nested inside a further set of ix:nonNumeric tags. The date would appear twice in the Target Document, once for each ix:nonNumeric element. If the date was in the form, say, "July 14, 1789" then both ix:nonNumeric elements would include the attribute format="ixt:datelongus", and both dates in the Target Document would appear in the canonical form "1789-07-14".

By using the ix:exclude element it is possible to remove part of the content of the ix:nonNumeric element from the output in the Target Document. But any ix: tags which are nested within that ix:exclude element will continue to be processed in their own right (although no longer as part of the host ix:nonNumeric element).

5.7 Nested numeric tags

Inline XBRL v1.1 introduced the nesting of ix:fraction and ix:nonFraction elements. To ensure that the content continues to meet the requirements of the numeric content in [XBRL 2.1], there are some specific constraints on the nesting.

ix:nonFraction only allows "close" nesting, i.e. it either has a child ix:nonFraction element or it has text content, but not both; and it does not accept Markup Element descendants. The ix:fraction element continues to allow child Markup Elements, but if it is nested with other ix:fraction elements they are required to share the same ix:numerator and ix:denominator descendants.

5.8 Nested tuples

Tuples can be nested, either physically or by reference (the latter by using tupleRef and tupleID). There is no limit to the recursion, except that it is not permitted for tuple content to include, in its own tuple content, the parent tuple.

5.9 Signs

Inline XBRL requires that numerics (ix:denominator, ix:numerator and ix:nonFraction) must use the sign attribute to indicate negative values. Any negative indicator (dash, brackets, or colour-coding) must be positioned in the Inline XBRL Document outside the relevant Inline XBRL Element. The content of the relevant Inline XBRL Element will therefore always be a non-negative number, unless the format attribute is present and a transformation is thus indicated.

Data values which are to be transformed must either represent non-numerics (e.g. dates) or they must also represent (allowing for commas and other formatting) non-negative numerics. No transformation may be used to change the sign of the content. This enforces the general requirement that all numeric values in Inline XBRL are always positive, and values which are required to be negative in the Target Document may only be represented by use of the sign attribute.

5.10 Other attributes

[XBRL 2.1] allows the addition of attributes, other than those defined in the [Inline XBRL Specification], to an XBRL instance document. For instance, it may be desired to give xml:id attributes to elements in the XBRL instance document. Inline XBRL allows the matching addition of "other attributes", in a number of places, to provide for this.

Note that for some elements (ix:footnote, ix:denominator and ix:numerator) the definition of "other attributes" is explicitly more permissive than is the attribute model for that element. This is because definitions which explicitly matched the attribute model would not, in fact, encompass attributes such as those with the http://www.w3.org/2001/XMLSchema-instance namespace name which are not referenced in the schema but which are legal in both Inline XBRL and XBRL v2.1. In the case of ix:denominator and ix:numerator, attributes with the http://www.w3.org/2001/XMLSchema-instance namespace name are actually the only legal members of "other attributes".

Note also that some "other attributes" are defined as attributes with a namespace name other than http://www.xbrl.org/DPWD-2013-05-31/inlineXBRL. This requirement is not met by attributes which do not have any namespace at all. For more information it is worth consulting [XML Names].

5.11 xml:lang

The attribute xml:lang is handled by the rules controlling "other attributes". This means that ix:footnote and ix:nonNumeric elements (or their ancestor elements) can be assigned a language which will be carried through to the XBRL facts in the Target Document. The same elements can be included in ix:hidden with an alternative xml:lang attribute value, and this will also be carried through to the Target Document where an XBRL processor will treat it as an alternative language value for the same fact.

In theory, an entire IXDS could be constructed from Inline XBRL Documents using different xml:lang attributes.

6 Formatting

6.1 Markup elements in text data

The Inline XBRL equivalents to XBRL text-based facts are ix:footnote and ix:nonNumeric. There are some important differences in the treatment of the content of these elements. Neither has any restriction on element content; in practice this means the content may be ix: elements or Markup Elements. Both can therefore accommodate the nesting of ix: elements and both use the ix:exclude element to remove content from the mapped data.

However, they are very different in their treatment of Markup Elements. In Inline XBRL, most Markup Elements are discarded upon processing, but this is not the case for ix:footnote and ix:nonNumeric. The ix:footnote element includes full Markup Elements in its mappable value, in conformance with the content model for link:footnote in [XBRL 2.1]. However, [XBRL 2.1] does not allow Markup Elements in non-numeric facts. Inline XBRL provides that Markup Elements are only mapped to the Target Document if the escape attribute has been set to true, in which case the Markup Elements are XML-escaped in the Target Document. If the escape attribute is false, the HTML or XHTML tags are discarded prior to mapping.

6.1.1 ix:continuation

The ix:continuation element was introduced in Version 1.1 as a way of concatenating text to construct arbitrary ix:nonNumeric or ix:footnote elements. It is used in any place where you cannot insert ix:nonNumeric end tags and still maintain XML well-formedness. It is therefore suitable for situations where the ix:exclude element is not suitable.

Examples of this include documents where text blocks overlap; or where text elements are closed in mid-paragraph prior to insertion of a page break or page number.

The ix:continuation element is therefore used (either individually or as a chain) to add extra content to an existing ix:footnote or ix:nonNumeric element.

Note, however, that while ix:continuation elements may be explicitly nested, individual elements may not be used in multiple chains. This constraint is to simplify processing and to prevent recursion.

6.2 XLink support

XBRL uses [XLINK] to define relationships such as those between XBRL facts and footnote resources. Certain [XLINK] attributes are allowed in XBRL but are specifically given no meaning or semantics in [XBRL 2.1]. These include: http://www.w3.org/1999/xlink:actuate, http://www.w3.org/1999/xlink:show and http://www.w3.org/1999/xlink:title. Inline XBRL does not provide any mechanism for including these in the Target Document.

6.3 XML-escaping

XML-escaped Markup Elements, where they are found in non-numeric XBRL facts, is used most commonly in US SEC reporting, to provide some local formatting for large blocks of text.

XML-escaping may be achieved by escaping individual characters or by enclosing the text in a CDATA block. It is up to the Processor to determine whether to use CDATA blocks or character escaping, because both options are treated as equivalent in [XML].

The full definition of XML-escaping can be found in [XML]. In Inline XBRL, XML-escaping applies both to Markup Elements and Markup Elements that have already been escaped in the original ix:nonNumeric element. In the latter case, the mapped output will be "double-escaped". Note, however, that the XML specification forbids the nesting of CDATA blocks.

By way of example, the XML <b> Hello World </b> will be output as &lt;b&gt; Hello World &lt;/b&gt; . The XML > , which is escaped as &gt; , would be double-escaped as &amp;gt; .

7 Syntax

7.1 MIME types

The MIME type selected for the Inline XBRL Document will often have an impact on whether browsers display the document correctly. The MIME type can be set within the Inline XBRL Document with code such as: <meta content='text/html; charset=utf-8' http-equiv='Content-Type' /> .

It should also be noted that browsers may also depend upon the filename suffix in order to determine display behaviour.

Authors of Inline XBRL Documents should test how their documents display in different browsers to ensure that the MIME type is set appropriately.

7.2 Namespace declarations

The display of Inline XBRL documents in different browsers is, regrettably, sometimes dependent upon the location of the namespace declarations in the document. In particular, placing the XHTML namespace declaration (xmlns:html="http://www.w3.org/1999/xhtml") anywhere in the body of the Inline XBRL document is likely to lead to undefined treatment in many browsers.

It is advisable to define the XHTML namespace as the default in the root HTML element and nowhere else.

7.3 Page breaks

Inline XBRL supports page breaks in printed output.

Include the markup <p style="page-break-before: always" /> to force a page break when the document is printed from most common browsers.

7.4 QNames in attributes

In Inline XBRL, the name of the XBRL element type in the Target Document is determined by the value of the relevant name attribute in the Inline XBRL Document. The name attribute is a QName, that is, it is in the form namespace prefix:local name.

So that the namespace prefix can be expanded to the underlying namespace name, it is essential to make sure that all name attributes fall within the scope of the appropriate namespace declaration.

There is a general rule (Section 3.3.2 of the [Inline XBRL Specification]) which requires that namespaces are handled in accordance with the namespaces specification, which is interpreted by Processors as requiring these declarations to be made available within the Target Document.

Note that it should not be necessary to provide a namespace declaration for every name attribute. As long as there is an appropriate namespace declaration in scope for the attribute, the QName will be treated correctly in the Target Document.

Canonicalisation [C14N] of the Inline XBRL document, which will remove similar namespace declarations with an overlapping scope, will not have any impact on the validity of the Target Document.

Remember to make sure that there is an appropriate namespace declaration in scope for all QNames which are used in the Inline XBRL Document.

7.5 URIs in Markup elements

Markup which is mapped to the target document (as is the case with Markup Elements included in ix:footnote elements and some ix:nonNumeric elements) may contain URIs.

In HTML and XHTML, URIs may be absolute or relative. In the absence of any alternative, relative URIs will be converted to absolute URIs by Processors using contextual information (such as current document location). This is unattractive for Inline XBRL, where the Inline XBRL document may be part of an electronic filing with no pre-determined location, and can lead to unpredictable results.

Unless hyperlinking between parts of the IXDS, authors should either use absolute URIs or they should provide a base URI by including the BASE element in the HEAD element of the Inline XBRL document.

This topic is covered more fully in section 12.4.1 of the [HTML] specification.

7.6 URIs in Inline XBRL Elements

Inline XBRL Element URIs, like URIs in Markup Elements, need to be capable of resolution to absolute URIs as part of the mapping process. A common example of this is the xlink:href attribute.

The resolution of relative URIs in Inline XBRL Elements is controlled by the xml:base attribute.

Authors should either use absolute URIs in Inline XBRL Elements or they should use the xml:base attribute.

8 Discussion of consuming applications

In general, it has been assumed that Inline XBRL will be consumed by standalone Processors that will convert the Inline XBRL into an XBRL instance document which will then be passed on to another application for further analysis or storage. However, some use cases suggest that embedded applications (for instance, JavaScript executed by a browser) might also be used to process the Inline XBRL.

8.1 Hidden elements

Some elements which are required in the XBRL are not expected to be displayed. For instance, a value may be repeated several times in an XBRL instance document, each time as a different concept. Where the convention is only to display this value once, the other occurrences are not displayed in the Markup. Inline XBRL uses the convention that such values will be placed in the ix:hidden element.

However, use of the hidden area opens the possibility that data which will in due course be processed and validated may be deliberately hidden from view. We expect that applications consuming Inline XBRL for further processing will search for tagged data which has not been displayed, to check that it is properly placed in the hidden area. Likewise, the consuming application would provide users with a way to inspect data in the hidden area.

8.2 DOM

There is a general caution with respect to Inline XBRL for in-browser processing. Inline XBRL uses several XML namespaces to provide for more reliable data processing. Within the browser, however, different browsers may expose Inline XBRL Elements to the [HTML DOM] in different ways. Web designers looking to access Inline XBRL metadata should be careful to take this into account.

Appendix A References

C14N
W3C (World Wide Web Consortium). "Canonical XML"
John Boyer.

(See http://www.w3.org/TR/xml-c14n)
HTML
W3C (World Wide Web Consortium). "HTML 4.01 Specification"
Dave Raggett
, Arnaud Le Hors, and Ian Jacobs.
(See http://www.w3.org/TR/html401/)
HTML DOM
W3C (World Wide Web Consortium). "Document Object Model (DOM) Level 2 HTML Specification"
Johnny Stenback
, Philippe Le Hégaret, and Arnaud Le Hors.
(See http://www.w3.org/TR/DOM-Level-2-HTML)
Inline XBRL Schema
XBRL International Inc.. "Inline XBRL Part 2: Schema 1.1"
Philip Allen
, and Ian Stokes-Rees.
(See http://www.xbrl.org/Specification/inlineXBRL-part2/DPWD-2013-05-31/inlineXBRL-part2-DPWD-2013-05-31.html)
Inline XBRL Specification
XBRL International Inc.. "Inline XBRL Part 1: Specification 1.1"
Philip Allen
, and Ian Stokes-Rees.
(See http://www.xbrl.org/Specification/inlineXBRL-part1/DPWD-2013-05-31/inlineXBRL-part1-DPWD-2013-05-31.html)
XBRL 2.1
XBRL International Inc.. "Extensible Business Reporting Language (XBRL) 2.1 Includes Corrected Errata Up To 2013-02-20"
Phillip Engel
, Walter Hamscher, Geoff Shuetrim, David vun Kannon, and Hugh Wallis.
(See http://www.xbrl.org/Specification/XBRL-2.1/REC-2003-12-31/XBRL-2.1-REC-2003-12-31+corrected-errata-2013-02-20.html)
XLINK
W3C (World Wide Web Consortium). "XML Linking Language (XLink) Version 1.0"
Steve DeRose
, Eve Maler, and David Orchard.
(See http://www.w3.org/TR/xlink/)
XML
W3C (World Wide Web Consortium). "Extensible Markup Language (XML) 1.0 (Fifth Edition)"
Tim Bray
, Jean Paoli, C. M. Sperberg-McQueen, Eve Maler, and François Yergeau.
(See http://www.w3.org/TR/REC-xml/)
XML Names
W3C (World Wide Web Consortium). "Namespaces in XML 1.0 (Third Edition)"
(See http://www.w3.org/TR/2009/REC-xml-names-20091208)
XML Schema Datatypes
W3C (World Wide Web Consortium). "XML Schema Part 2: Datatypes Second Edition"
Paul V. Biron
, and Ashok Malhotra.
(See http://www.w3.org/TR/xmlschema-2/)

Appendix B Intellectual property status (non-normative)

This document and translations of it may be copied and furnished to others, and derivative works that comment on or otherwise explain it or assist in its implementation may be prepared, copied, published and distributed, in whole or in part, without restriction of any kind, provided that the above copyright notice and this paragraph are included on all such copies and derivative works. However, this document itself may not be modified in any way, such as by removing the copyright notice or references to XBRL International or XBRL organizations, except as required to translate it into languages other than English. Members of XBRL International agree to grant certain licenses under the XBRL International Intellectual Property Policy (www.xbrl.org/legal).

This document and the information contained herein is provided on an "AS IS" basis and XBRL INTERNATIONAL DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.

The attention of users of this document is directed to the possibility that compliance with or adoption of XBRL International specifications may require use of an invention covered by patent rights. XBRL International shall not be responsible for identifying patents for which a license may be required by any XBRL International specification, or for conducting legal inquiries into the legal validity or scope of those patents that are brought to its attention. XBRL International specifications are prospective and advisory only. Prospective users are responsible for protecting themselves against liability for infringement of patents. XBRL International takes no position regarding the validity or scope of any intellectual property or other rights that might be claimed to pertain to the implementation or use of the technology described in this document or the extent to which any license under such rights might or might not be available; neither does it represent that it has made any effort to identify any such rights. Members of XBRL International agree to grant certain licenses under the XBRL International Intellectual Property Policy (www.xbrl.org/legal).

Appendix C Acknowledgements (non-normative)

This document could not have been written without the contributions of many people.

Appendix D Document history (non-normative)

DateAuthorDetails
20 April 2010

Recommendation v1.0

26 May 2010Philip Allen

Added note on the limited footnote model.

17 November 2010Philip Allen

Added note about interpretation of "namespace name".

22 December 2011Philip Allen

Added note about handling of xml:lang.

28 February 2013Philip Allen

Added note on the limited footnote model.

Added note about interpretation of "namespace name".

Added note about handling of xml:lang.

Added note about limited support for XLink.

Added note describing ix:continuation.

Added note about nesting of numeric elements.

Added overview about v1.1.

23 May 2013Philip Allen

Added note on use of meta tags.

1 June 2013Philip Allen

Added purpose and functionality of specification.

Appendix E Errata corrections in this document

This appendix contains a list of the errata that have been incorporated into this document. This represents all those errata corrections that have been approved by the XBRL International Rendering Working Group up to and including 31 May 2013.