You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by da...@apache.org on 2015/04/15 23:26:40 UTC

[17/42] isis git commit: ISIS-1133: reworked template to use zurb foundation, and reference the regular asciidoctor stylesheets; skeleton outline of about half of the website.

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-config.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-config.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-config.adoc
new file mode 100644
index 0000000..9771f4c
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-config.adoc
@@ -0,0 +1,46 @@
+= User Guide: Configuration
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## Configuration
+
+Isis' own configuration properties are simple key-value pairs, typically held in in the `WEBINF/isis.properties` file.
+
+## Configuring the Webapp
+
+When running an Isis webapp, configuration properties are read from configuration files held in the `WEB-INF` directory.
+
+### Isis configuration
+
+The `WEBINF/isis.properties` file is always read and must exist.
+
+In addition, the following other properties are searched for and if present also read:
+
+* `viewer_wicket.properties` - if the Wicket UI (viewer) is in use
+* `viewer_restfulobjects.properties` - if the Restful Objects REST API (viewer) is in use
+* `viewer.properties` - for any shared UI configuration
+* `persistor_datanucleus.properties` - assuming the JDO/DataNucleus objectstore is in use
+* `persistor.properties` - for any shared objectstore configuration.  This typically is used to hold `JDBC` ``URL``s
+
+### Shiro configuration
+
+`WEB-INF/shiro.ini`
+
+### JDO/DataNucleus configuration
+
+Any Isis properties with the prefix `isis.persistor.datanucleus.impl` are passed through directly to the JDO/DataNucleus objectstore (with the prefix stripped off, of course).
+
+DataNucleus will itself search for additional XML mapping files, eg `mappings.jdo`.  These an be used to override any annotations of annotated entities.
+
+## Configuring the Integration Tests
+
+Integration tests are configured programmatically, with a default set of properties to bootstrap the JDO/DataNucleus objectstore using an HSQLDB in-memory database.
+
+These can be overridden by subclassing `IsisConfigurationForJdoIntegTests`.
+
+## Reference
+
+### Deployment Types
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-apache-isis-vs.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-apache-isis-vs.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-apache-isis-vs.adoc
new file mode 100644
index 0000000..f069d41
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-apache-isis-vs.adoc
@@ -0,0 +1,14 @@
+= User Guide: Core Concepts: Apache Isis vs ...
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## vs Spring
+
+## vs JEE
+
+## vs Grails
+
+## vs Angular

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-building-blocks.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-building-blocks.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-building-blocks.adoc
new file mode 100644
index 0000000..1122eae
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-building-blocks.adoc
@@ -0,0 +1,58 @@
+= User Guide: Core Concepts: Building Blocks
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## A MetaModel with Explicit and Inferred Semantics
+
+* use of annotations
+** reuse JEE annotations where possible
+* layout hints are overridable, to avoid restarting the app/speed up feedback
+
+
+## Domain Objects and Domain Services
+
+* domain model
+** domain objects
+*** domain entity
+*** view model
+** domain service
+** value type
+
+Anything else can be (should be) ignored by annotating with `@Programmatic`.
+
+
+
+## Properties, Collections and Actions
+
+
+
+## Domain Entities vs View Models
+
+`@DomainObject(nature=...)`
+
+
+
+## Domain Services
+
+### Domain Services vs View Services
+
+`@DomainService(nature=...)`
+
+### Factories, Repositories, Services
+
+
+## Value Objects (Primitives)
+
+
+
+## Contributions
+
+
+
+## Event Bus
+
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-framework-provided-services.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-framework-provided-services.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-framework-provided-services.adoc
new file mode 100644
index 0000000..5379fa2
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-framework-provided-services.adoc
@@ -0,0 +1,17 @@
+= User Guide: Core Concepts: Framework-provided Services
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+## The `DomainObjectContainer` service
+
+NOTE: TODO
+
+## Other Services
+
+NOTE: TODO
+
+
+
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-principles.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-principles.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-principles.adoc
new file mode 100644
index 0000000..7653485
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts-principles.adoc
@@ -0,0 +1,70 @@
+= User Guide: Core Concepts: Principles
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## Domain-Driven Design
+
+### Ubiquitous Language
+
+
+
+## Naked Objects Pattern
+
+.Object Interface Mapping
+====
+Just as an ORM (such as link:http://datanucleus.org[DataNucleus] or link:http:hibernate.org[Hibernate]) maps domain entities to a database, you can think of Naked Objects as an OIM - mapping domain objects to a user interface.
+====
+
+* multiple UIs.
+
+
+
+## Hexagonal Architecture
+
+[NOTE]
+====
+The hexagonal architecture is also known as the ports-and-adapters architecture.  another name used (less frequently) is the onion architecture.
+====
+
+
+
+## Decoupled Modules
+
+Using:
+
+* dependency injection of services
+* OO design techniques, eg dependency inversion principle
+* an in-memory event bus
+* applib
+
+.Aspect Oriented
+****
+Although not implemented using an aspect-oriented language such as AspectJ, Isis takes considerable inspiration from AOP concepts.
+
+For example, the UI visualization automatically provided by Isis can be thought of (and is!) treating the UI as a cross-cutting concern.
+
+Isis' also has support for traits/mixins through its <<Contributions>>.  This allows functionality from one class (a domain service) to be rendered as if it belongs to another (a domain object).
+
+
+* aspect-oriented design, such as traits/mix-ins (see <<Contributions>>) and interceptors and UI visualization as a cross-cutting concern
+****
+
+
+
+## Focuses on its Key Responsibilities
+
+* Isis is at heart a metamodel with runtime, and coordinates interations using an AOP set of principles
+* Apache Isis vs Isis Addons
+* Apache Isis vs Shiro vs DataNucleus
+
+
+
+## Testable Applications
+
+While Apache Isis can be used (very effectively) for simple CRUD-style applications, it is also intended to be used for complex business domains.  Ensuring that the business logic in such applications is correct means that the framework must (and does) provide robust testing support, both for developer-level unit testing and business-level (end-to-end) integration testing.
+
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts.adoc
new file mode 100644
index 0000000..63f7b70
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-core-concepts.adoc
@@ -0,0 +1,34 @@
+= User Guide: Core Concepts
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## Principles
+
+include::user-guide-core-concepts-principles.adoc[leveloffset=+1]
+
+
+
+## Apache Isis vs...
+
+include::user-guide-core-concepts-apache-isis-vs.adoc[leveloffset=+1]
+
+
+
+## Building Blocks
+
+include::user-guide-core-concepts-building-blocks.adoc[leveloffset=+1]
+
+
+## Framework-provided Services
+
+include::user-guide-core-concepts-framework-provided-services.adoc[leveloffset=+2]
+
+
+
+## Honouring the Single Responsibility Principle
+
+### Behaviourally Complete vs Contributions
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-business-rules.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-business-rules.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-business-rules.adoc
new file mode 100644
index 0000000..879b810
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-business-rules.adoc
@@ -0,0 +1,57 @@
+= User Guide: How-tos: Business Rules
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## Visibility ("see it")
+
+### Hide a Property
+
+### Hide a Collection
+
+### Hide an Action
+
+### Hide a Contributed Property, Collection or Action
+
+### All Members Hidden
+
+## Usability ("use it")
+
+### Disable a Property
+
+### Disable a Collection
+
+### Disable an Action
+
+### Disable a Contributed Property, Collection or Action
+
+### All Members Unmodifiable (Disabling the Edit Button)
+
+Sometimes an object is unmodifiable.
+
+In the Wicket viewer this means disabling the edit button.
+
+#### Declarative
+
+`@DomainObject(editing=...)`
+
+#### Imperative
+
+
+
+## Validity ("do it")
+
+### Validate (change to) a Property
+
+### Validate (adding or removing from) a Collection
+
+### Validate (arguments to invoke) an Action
+
+### Validating a Contributed Property, Collection or Action
+
+### Declarative validation using `@MustSatisfy`
+
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-class-members.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-class-members.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-class-members.adoc
new file mode 100644
index 0000000..ebb4ae2
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-class-members.adoc
@@ -0,0 +1,104 @@
+= User Guide: How-tos: Class Members
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## Property
+
+
+### Value vs Reference Types
+
+
+The annotations for mapping value types tend to be different for properties vs action parameters, because JDO annotations are only valid on properties.  The table in <<Mapping Value Types>> provides a handy reference for the each.
+
+### Optional Properties
+
+
+### Mapping String (Length)
+
+### Mapping JODA Dates
+
+### Mapping BigDecimals
+
+### Mapping Blobs
+
+### Mapping Passwords
+
+
+[NOTE]
+.Lazy Loading
+====
+
+====
+
+
+## Collection
+
+
+[NOTE]
+====
+While Isis support collections of references, the framework (currently) does not support collections of values. That is, it isn't possible to define a collection of type `Set<String>`.
+
+Or, actually, you can, because that is a valid mapping supported by JDO/DataNucleus .  However, Isis has no default visualization.
+
+The workaround is to mark the collection as `@Programmatic`, as described in <<Ignoring Methods>>.  This ensures that the collection is ignored by Isis.
+===
+
+## Actions
+
+[NOTE]
+====
+While Isis support actions whose parameters' types are scalar (values such as `String`, `int`, or references such as `Customer`), the framework (currently) does not support parameter types that are collections or maps.
+
+The workaround is to mark the collection as `@Programmatic`, as described in <<Ignoring Methods>>.  This ensures that the collection is ignored by Isis.
+====
+
+
+### Optional Action Argument
+
+## String Length Of Action Parameter
+
+## BigDecimal Precision Of Action Parameter
+
+### Mapping String (Length)
+
+### Mapping JODA Dates
+
+### Mapping BigDecimals
+
+### Mapping Blobs
+
+
+
+## Mapping Value Types
+
+table of:
+.
+|value type
+|property
+|action parameter
+
+|string (length)
+|
+|
+
+|big decimal (precision)
+|
+|
+
+|Isis blob
+|
+|
+
+|optional
+|`@Column(allowsNull="true")`
+|`ParameterLayout(optionality=Optionality.OPTIONAL`) or `@Optional`
+
+
+## Ignoring Methods
+
+Sometimes you want to define a `public` method on a domain object that is not intended to be rendered in Isis' UI.
+
+To exclude such methods, use the `@Programmatic` annotation.

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-contributed-members.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-contributed-members.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-contributed-members.adoc
new file mode 100644
index 0000000..ca8a099
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-contributed-members.adoc
@@ -0,0 +1,15 @@
+= User Guide: How-tos: Contributed Members
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## Contributed Action
+
+## Contributed Property
+
+## Contributed Collection
+
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-crud.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-crud.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-crud.adoc
new file mode 100644
index 0000000..6cd85e8
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-crud.adoc
@@ -0,0 +1,18 @@
+= User Guide: How-tos: Object Management (CRUD)
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## Injecting Services
+
+## Instantiating and Persisting Objects
+
+## Finding Objects
+
+## Deleting Objects
+
+
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-derived-members.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-derived-members.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-derived-members.adoc
new file mode 100644
index 0000000..9640959
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-derived-members.adoc
@@ -0,0 +1,33 @@
+= User Guide: How-tos: Derived Members
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## Derived Property
+
+## Derived Collection
+
+
+.Inlining query-only repository action
+****
+While derived properties and derived collections typically "walk the graph" to associated objects, there is nothing to prevent the returned value being the result of invoking a repository (domain service) action.
+
+For example:
+
+[source,java]
+----
+public class Customer {
+    ...
+    public List<Order> getMostRecentOrders() {
+        return orderRepo.findMostRecentOrders(this, 5);
+    }
+}
+----
+****
+
+## Trigger on property change
+
+## Trigger on collection change
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-drop-downs-and-defaults.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-drop-downs-and-defaults.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-drop-downs-and-defaults.adoc
new file mode 100644
index 0000000..b05ac1d
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-drop-downs-and-defaults.adoc
@@ -0,0 +1,30 @@
+= User Guide: How-tos: Business Rules
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## For Properties
+
+### Choices for Property
+
+### Auto-complete for property
+
+### Default for property
+
+## For Action Parameters
+
+### Choices for action parameter
+
+### Dependent choices for action params
+
+### Auto-complete for action param
+
+### Default for action param
+
+## For both Properties and Action Parameters
+
+### Drop-down for limited number of instances
+
+### Auto-complete (repository-based)
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-entity-relationships.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-entity-relationships.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-entity-relationships.adoc
new file mode 100644
index 0000000..ec8ab6a
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-entity-relationships.adoc
@@ -0,0 +1,11 @@
+= User Guide: How-tos: Entity Relationships
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## Mapping Mandatory and Optional Properties
+
+## Managed 1:m bidirectional relationships
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-ui-hints.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-ui-hints.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-ui-hints.adoc
new file mode 100644
index 0000000..f313112
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos-ui-hints.adoc
@@ -0,0 +1,35 @@
+= User Guide: How-tos: UI Hints
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## Icons and Titles
+
+### Object Title
+
+#### Titles in Tables
+
+#### Hide part of a title
+
+### Object Icon
+
+### Object CSS Styling
+
+
+## Names and Descriptions
+
+NOTE: see also i18n (TODO: convert to link)
+
+### Action Parameters
+
+
+## Layout
+
+### Layout using annotations
+
+### Dynamic layouts
+
+### Application menu layout
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos.adoc
new file mode 100644
index 0000000..c15020f
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-how-tos.adoc
@@ -0,0 +1,54 @@
+= User Guide: How-tos
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## Class Members
+
+include::user-guide-how-tos-class-members.adoc[leveloffset=+1]
+
+
+
+## Entity Relationships
+
+include::user-guide-how-tos-entity-relationships.adoc[leveloffset=+1]
+
+
+
+## Contributed Members
+
+include::user-guide-how-tos-contributed-members.adoc[leveloffset=+1]
+
+
+
+## Derived Members
+
+include::user-guide-how-tos-derived-members.adoc[leveloffset=+1]
+
+
+
+## Object Management (CRUD)
+
+include::user-guide-how-tos-crud.adoc[leveloffset=+1]
+
+
+
+## UI Hints
+
+include::user-guide-how-tos-ui-hints.adoc[leveloffset=+1]
+
+
+
+## Business Rules
+
+include::user-guide-how-tos-business-rules.adoc[leveloffset=+1]
+
+
+
+## Drop downs and Defaults
+
+include::user-guide-how-tos-drop-downs-and-defaults.adoc[leveloffset=+1]
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-convenience-superclasses.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-convenience-superclasses.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-convenience-superclasses.adoc
new file mode 100644
index 0000000..bb05b44
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-convenience-superclasses.adoc
@@ -0,0 +1,8 @@
+= User Guide: Reference: Convenience Superclasses
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-domain-services.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-domain-services.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-domain-services.adoc
new file mode 100644
index 0000000..2db6ae9
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-domain-services.adoc
@@ -0,0 +1,8 @@
+= User Guide: Reference: Domain Services
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-recognized-annotations.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-recognized-annotations.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-recognized-annotations.adoc
new file mode 100644
index 0000000..be58af2
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-recognized-annotations.adoc
@@ -0,0 +1,8 @@
+= User Guide: Reference: Recognized Annotations
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-recognized-methods.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-recognized-methods.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-recognized-methods.adoc
new file mode 100644
index 0000000..ae518f2
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-recognized-methods.adoc
@@ -0,0 +1,8 @@
+= User Guide: Reference: Recognized Methods
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-value-types.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-value-types.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-value-types.adoc
new file mode 100644
index 0000000..6942d2b
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference-value-types.adoc
@@ -0,0 +1,8 @@
+= User Guide: Reference: Value Types
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference.adoc
new file mode 100644
index 0000000..1dc7ccc
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide-reference.adoc
@@ -0,0 +1,27 @@
+= User Guide: Reference
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+NOTE: TODO
+
+## Recognized Methods
+
+include::user-guide-reference-recognized-methods.adoc[leveloffset=+1]
+
+## Recognized Annotations
+
+include::user-guide-reference-recognized-annotations.adoc[leveloffset=+1]
+
+## Domain Services
+
+include::user-guide-reference-domain-services.adoc[leveloffset=+1]
+
+## Value Types
+
+include::user-guide-reference-domain-services.adoc[leveloffset=+1]
+
+## Convenience Superclasses
+
+include::user-guide-reference-convenience-superclasses.adoc[leveloffset=+1]
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/documentation/src/main/asciidoc/user-guide/user-guide.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/user-guide/user-guide.adoc b/adocs/documentation/src/main/asciidoc/user-guide/user-guide.adoc
new file mode 100644
index 0000000..8febabb
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/user-guide/user-guide.adoc
@@ -0,0 +1,24 @@
+= User Guide
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+:toc: right
+:numbered:
+
+## Core Concepts
+
+include::user-guide-core-concepts.adoc[leveloffset=+1]
+
+## Reference
+
+include::user-guide-reference.adoc[leveloffset=+1]
+
+## How-tos
+
+include::user-guide-howtos.adoc[leveloffset=+2]
+
+## Configuration
+
+include::user-guide-config.adoc[leveloffset=+1]
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/pom.xml
----------------------------------------------------------------------
diff --git a/adocs/pom.xml b/adocs/pom.xml
index ff52d94..7ba0943 100644
--- a/adocs/pom.xml
+++ b/adocs/pom.xml
@@ -85,6 +85,7 @@
                         <templateDir>../template</templateDir>
                         <eruby>erb</eruby>
                         <preserveDirectories>true</preserveDirectories>
+                        <relativeBaseDir>true</relativeBaseDir>
                         <attributes>
                             <!--
                             in essence unsets the imagesdir attribute (the mojo hardcodes it to "images").
@@ -92,6 +93,7 @@
                             (but any other value seems to be incompatible with github's built-in rendering anyway)
                             -->
                             <imagesdir/>
+                            <toc>right</toc>
                             <icons>font</icons>
                             <latestStable>${version.isis.latest.stable}</latestStable>
                             <latestSnapshot>${version.isis.latest.snapshot}</latestSnapshot>

http://git-wip-us.apache.org/repos/asf/isis/blob/f95f3453/adocs/template/document.html.erb
----------------------------------------------------------------------
diff --git a/adocs/template/document.html.erb b/adocs/template/document.html.erb
index dc528fe..8c28612 100644
--- a/adocs/template/document.html.erb
+++ b/adocs/template/document.html.erb
@@ -1,58 +1,44 @@
-<%#encoding:UTF-8%><!DOCTYPE html>
+<!doctype html>
+<html class="no-js" lang="en">
 <head>
-<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
-<meta charset="utf-8">
-<meta name="viewport" content="width=device-width, initial-scale=1.0">
-<meta name="description" content="deltaspike-generate-pages">
-<meta name="author" content="chm">
-<!-- No caching headers -->
-<meta http-equiv="cache-control" content="no-cache" />
-<meta http-equiv="pragma" content="no-cache" />
-<meta http-equiv="expires" content="-1" />
+    <meta charset="utf-8"/>
+    <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
 
-<title><%= document.name %></title>
+    <title><%= document.name %></title>
 
-<!--
-    Licensed to the Apache Software Foundation (ASF) under one
-    or more contributor license agreements.  See the NOTICE file
-    distributed with this work for additional information
-    regarding copyright ownership.  The ASF licenses this file
-    to you under the Apache License, Version 2.0 (the
-    "License"); you may not use this file except in compliance
-    with the License.  You may obtain a copy of the License at
+    <!--
+        Licensed to the Apache Software Foundation (ASF) under one
+        or more contributor license agreements.  See the NOTICE file
+        distributed with this work for additional information
+        regarding copyright ownership.  The ASF licenses this file
+        to you under the Apache License, Version 2.0 (the
+        "License"); you may not use this file except in compliance
+        with the License.  You may obtain a copy of the License at
 
-    http://www.apache.org/licenses/LICENSE-2.0
+        http://www.apache.org/licenses/LICENSE-2.0
 
-    Unless required by applicable law or agreed to in writing,
-    software distributed under the License is distributed on an
-    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-    KIND, either express or implied.  See the License for the
-    specific language governing permissions and limitations
-    under the License.
--->
+        Unless required by applicable law or agreed to in writing,
+        software distributed under the License is distributed on an
+        "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+        KIND, either express or implied.  See the License for the
+        specific language governing permissions and limitations
+        under the License.
+    -->
 
-<!-- Styles -->
+    <!-- No caching headers -->
+    <meta http-equiv="cache-control" content="no-cache" />
+    <meta http-equiv="pragma" content="no-cache" />
+    <meta http-equiv="expires" content="-1" />
 
-<link rel="shortcut icon" href="<%= (attr :sitebasedir) %>/images/favicon.ico">
 
-<!-- selected portions of the default asciidoctor-default CSS -->
-<link href="<%= (attr :_basedir) %>css/asciidoctor/font-icon-styles.css" rel="stylesheet">
+    <link rel="stylesheet" href="<%= (attr :_basedir) %>css/foundation/5.5.1/foundation.css"/>
+    <script src="<%= (attr :_basedir) %>js/foundation/5.5.1/vendor/modernizr.js"></script>
 
-<script type="text/javascript" src="<%= (attr :_basedir) %>js/jquery/2.1.3/jquery.min.js"></script>
-<link href="<%= (attr :_basedir) %>css/bootstrap/3.3.4/bootstrap.min.css" rel="stylesheet">
-<script src="<%= (attr :_basedir) %>js/bootstrap/3.3.4/bootstrap.min.js"></script>
-<link href="<%= (attr :_basedir) %>css/font-awesome/4.3.0/css/font-awesome.min.css" rel="stylesheet">
+    <link href="<%= (attr :_basedir) %>css/asciidoctor/stylesheets/foundation-potion.css" rel="stylesheet">
 
+    <link href="<%= (attr :_basedir) %>css/font-awesome/4.3.0/css/font-awesome.min.css" rel="stylesheet">
 
-<style type="text/css">
-<%= ::Asciidoctor::Stylesheets.instance.coderay_stylesheet_data %>
-
-        body {
-          padding-top: 60px;
-          padding-bottom: 40px;
-        }
-
-       
+    <style type="text/css">
         #forkongithub a{
             display: none;
             background:#090;
@@ -110,259 +96,290 @@
                 box-shadow:4px 4px 10px rgba(0,0,0,0.8);
             }
         }
+    </style>
 
-body {
-  position: relative;
-}
-
-div#toc li {
-    list-style-type: none;
-}
-
-div#toc li.active-region:before {
-    content: "\00BB \0020";
-    margin-left: -12px;
-}
-
-div#toc li a.active {
-    color: red;
-}
-
-div#toc li.active-region li.active-region {
-    border-left: none;
-}
-
-div#toc ul {
-    -webkit-padding-start: 20px;
-}
-
-.imageblock .title {
-    padding-bottom: 30px;
-}
-
-div#toc {
-    position: fixed;
-    top: 20px;
-    height: 2000px;
-    padding-top: 120px;
-    padding-right: 10px;
-    border-left-color: #eee;
-    border-left-style: solid;
-}
-
-h4 {
-    font-size: 22px;
-}
-
-h5 {
-    font-size: 20px;
-    font-style: italic;
-}
-</style>
-
-    <!-- courtesy of http://codepo8.github.io/css-fork-on-github-ribbon/ -->
-    <span id="forkongithub">
-        <a href="https://github.com/apache/isis">Fork me on GitHub</a>
-    </span>
-    
-    
-</head>
+    <style>
+        body {
+          position: relative;
+        }
 
-<body>
+        body div#toc li,
+        body div#toc2 li {
+            list-style-type: none;
+        }
 
-    <nav class="navbar navbar-fixed-top navbar-inverse" role="navigation">
-      <div class="container">
-        <a class="navbar-brand" href="<%= (attr :sitebasedir) %>/index.html">Apache Isis&trade;</a>
-        <ul class="nav navbar-nav">
-
-            <li class="active dropdown">
-              <a href="#" class="dropdown-toggle" data-toggle="dropdown">Demos<b class="caret"></b></a>
-              <ul class="dropdown-menu">
-                <li><a href="<%= (attr :sitebasedir) %>/intro/elevator-pitch/isis-in-pictures.html">Screenshots</a></li>
-                <li><a href="<%= (attr :sitebasedir) %>/intro/tutorials/screencasts.html">Screencasts&nbsp;<img src="<%= (attr :sitebasedir) %>/images/tv_show-25.png"></a></li>
-                <li><a href="<%= (attr :sitebasedir) %>/intro/powered-by/powered-by.html">Powered by</a></li>
-                <li><a href="http://isisdemo.mmyco.co.uk/" target="_blank">Online Demo</a></li>
-              </ul>
-            </li>
-
-            <li><a href="<%= (attr :sitebasedir) %>/documentation">Documentation</a></li>
-
-            <li class="dropdown">
-              <a href="#" class="dropdown-toggle" data-toggle="dropdown">Downloads<b class="caret"></b></a>
-              <ul class="dropdown-menu">
-                <li><a href="<%= (attr :sitebasedir) %>/intro/getting-started/simpleapp-archetype.html">Isis (Maven archetype)</a></li>
-                <li><a href="<%= (attr :sitebasedir) %>/download.html">Isis (downloads)</a></li>
-                <li><a href="http://www.isisaddons.org" target="_blank">Isis Add-ons (not ASF)</a></li>
-              </ul>
-            </li>
-
-            <li class="dropdown">
-              <a href="#" class="dropdown-toggle" data-toggle="dropdown">Help<b class="caret"></b></a>
-              <ul class="dropdown-menu">
-                <li><a href="<%= (attr :sitebasedir) %>/support.html">Mailing Lists</a></li>
-                <li><a href="http://isis.markmail.org/search/?q=" target="_blank">Mailing List Archives</a></li>
-                <li><a href="https://issues.apache.org/jira/browse/ISIS" target="_blank">JIRA</a></li>
-                <li><a href="http://github.com/apache/isis" target="_blank">Github mirror</a></li>
-                <li><a href="http://stackoverflow.com/questions/tagged/isis" target="_blank">Stack Overflow</a></li>
-                <li><a href="<%= (attr :sitebasedir) %>/contributors/contributing.html">How to contribute</a></li>
-              </ul>
-            </li>
-
-            <li class="dropdown navbar-right">
-              <a href="#" class="dropdown-toggle" data-toggle="dropdown">@ASF<b class="caret"></b></a>
-              <ul class="dropdown-menu">
-                <li>
-                  <a href="http://www.apache.org/" target="_blank">Apache Homepage <i class="icon-share-alt"></i></a>
-                </li>
-                <li>
-                  <a href="http://www.apache.org/licenses/" target="_blank">Licenses <i class="icon-share-alt"></i></a>
-                </li>
-                <li>
-                  <a href="http://www.apache.org/security/" target="_blank">Security <i class="icon-share-alt"></i></a>
-                </li>
-                <li>
-                  <a href="http://www.apache.org/foundation/sponsorship.html" target="_blank">Sponsorship <i class="icon-share-alt"></i></a>
-                </li>
-                <li>
-                  <a href="http://www.apache.org/foundation/thanks.html">Thanks <i class="icon-share-alt"></i></a>
-                </li>
-                <li>
-                  <a href="{{base}}more-thanks.html">More thanks <i class="icon-share-alt"></i></a>
-                </li>
-              </ul>
-            </li>
-        </ul>
+        div#doc-content {
+            margin-top: 30px;
+        }
 
-        <FORM class="searchbox navbar-form navbar-right" id="searchbox_012614087480249044419:dn-q5gtwxya" action="http://www.google.com/cse">
-            <div class="form-group">
-                <input type="hidden" name="cx" value="012614087480249044419:dn-q5gtwxya">
-                <INPUT type="hidden" name="cof" value="FORID:0">
-                <INPUT class="form-control" name="q" type="text" placeholder="Search">
-            </div>
-        </FORM>
+        body div#toc li.active-region:before,
+        body div#toc2 li.active-region:before {
+            content: "\00BB \0020";
+            margin-left: -12px;
+        }
 
-      </div>
+        body div#toc li a.active,
+        body div#toc2 li a.active {
+            color: red;
+        }
+
+        body div#toc.toc,
+        body div#toc.toc2 {
+            position: fixed;
+            left: auto;
+            padding-top: 120px;
+            z-index: auto;
+            background-color: white;
+            border-left-color: #eee;
+            border-left-style: solid;
+            border-right: none;
+        }
+    </style>
 
-  </nav>
+</head>
+<body>
 
-  
+    <span id="forkongithub">
+        <a href="https://github.com/apache/isis">Fork me on GitHub</a>
+    </span>
 
-  <div class="container">
+<div class="row">
 
-    <div class="row">
-      <div class="col-md-12">
-        <div class="page-title">
-          <h1><%= document.name %></h1>
-        </div>
-      </div>
+    <div class="fixed contain-to-grid">
+        <nav class="top-bar" data-topbar role="navigation">
+            <ul class="title-area">
+                <li class="name">
+                    <h1>
+                        <a href="<%= (attr :sitebasedir) %>/index.html">Apache Isis&trade;</a>
+                    </h1>
+                </li>
+                <!-- Remove the class "menu-icon" to get rid of menu icon. Take out "Menu" to just have icon alone -->
+                <li class="toggle-topbar menu-icon"><a href="#"><span>Menu</span></a></li>
+            </ul>
+
+            <section class="top-bar-section">
+                <ul class="right">
+
+                    <li class="has-form">
+                       <FORM class="searchbox navbar-form navbar-right" id="searchbox_012614087480249044419:dn-q5gtwxya" action="http://www.google.com/cse">
+                        <div class="row collapse">
+                            <input type="hidden" name="cx" value="012614087480249044419:dn-q5gtwxya">
+                            <INPUT type="hidden" name="cof" value="FORID:0">
+                            <INPUT class="form-control" name="q" type="text" placeholder="Search">
+                        </div>
+                    </FORM>
+                     </li>
+
+                </ul>
+
+                <!-- Left Nav Section -->
+                <ul class="left">
+
+                    <li class="has-dropdown">
+                      <a href="#" >Demos</b></a>
+                      <ul class="dropdown">
+                        <li><a href="<%= (attr :sitebasedir) %>/intro/elevator-pitch/isis-in-pictures.html">Screenshots</a></li>
+                        <li><a href="<%= (attr :sitebasedir) %>/intro/tutorials/screencasts.html">Screencasts&nbsp;<img src="<%= (attr :sitebasedir) %>/images/tv_show-25.png"></a></li>
+                        <li><a href="<%= (attr :sitebasedir) %>/intro/powered-by/powered-by.html">Powered by</a></li>
+                        <li><a href="http://isisdemo.mmyco.co.uk/" target="_blank">Online Demo</a></li>
+                      </ul>
+                    </li>
+
+                    <li><a href="<%= (attr :sitebasedir) %>/documentation">Documentation</a></li>
+
+                    <li class="has-dropdown">
+                      <a href="#">Downloads</a>
+                      <ul class="dropdown">
+                        <li><a href="<%= (attr :sitebasedir) %>/intro/getting-started/simpleapp-archetype.html">Isis (Maven archetype)</a></li>
+                        <li><a href="<%= (attr :sitebasedir) %>/download.html">Isis (downloads)</a></li>
+                        <li><a href="http://www.isisaddons.org" target="_blank">Isis Add-ons (not ASF)</a></li>
+                      </ul>
+                    </li>
+
+                    <li class="has-dropdown">
+                      <a href="#">Help</a>
+                      <ul class="dropdown">
+                        <li><a href="<%= (attr :sitebasedir) %>/support.html">Mailing Lists</a></li>
+                        <li><a href="http://isis.markmail.org/search/?q=" target="_blank">Mailing List Archives</a></li>
+                        <li><a href="https://issues.apache.org/jira/browse/ISIS" target="_blank">JIRA</a></li>
+                        <li><a href="http://github.com/apache/isis" target="_blank">Github mirror</a></li>
+                        <li><a href="http://stackoverflow.com/questions/tagged/isis" target="_blank">Stack Overflow</a></li>
+                        <li><a href="<%= (attr :sitebasedir) %>/contributors/contributing.html">How to contribute</a></li>
+                      </ul>
+                    </li>
+
+                    <li class="has-dropdown">
+                      <a href="#" >@ASF</a>
+                      <ul class="dropdown">
+                        <li>
+                          <a href="http://www.apache.org/" target="_blank">Apache Homepage <i class="icon-share-alt"></i></a>
+                        </li>
+                        <li>
+                          <a href="http://www.apache.org/licenses/" target="_blank">Licenses <i class="icon-share-alt"></i></a>
+                        </li>
+                        <li>
+                          <a href="http://www.apache.org/security/" target="_blank">Security <i class="icon-share-alt"></i></a>
+                        </li>
+                        <li>
+                          <a href="http://www.apache.org/foundation/sponsorship.html" target="_blank">Sponsorship <i class="icon-share-alt"></i></a>
+                        </li>
+                        <li>
+                          <a href="http://www.apache.org/foundation/thanks.html">Thanks <i class="icon-share-alt"></i></a>
+                        </li>
+                        <li>
+                          <a href="{{base}}more-thanks.html">More thanks <i class="icon-share-alt"></i></a>
+                        </li>
+                      </ul>
+                    </li>
+
+                </ul>
+
+            </section>
+        </nav>
     </div>
-    <div class="row">
-      <div class="col-md-8">
+</div>
+
+<div class="row">
+    <div class="large-8 medium-8 columns">
+
         <div id="doc-content">
           <%= document.content %>
         </div>
-      </div>
-      <div class="col-md-4">
-        <div id="toc" class="<%= attr 'toc-class', 'toc' %>">
-          <%= converter.convert_with_options @document, 'outline', :toclevels => 4  %>
-        </div>
-      </div>
-    </div>
-    <div class="row">
-      <div class="col-md-12">
+
         <hr>
         <footer>
-          <p>
-          Copyright &copy; 2010~2015 The Apache Software Foundation, Licensed under the Apache License, Version 2.0.
+          <p class="small">
+          Copyright &copy; 2010~2015 The Apache&nbsp;Software&nbsp;Foundation, licensed under the Apache&nbsp;License,&nbsp;v2.0.
           <br/>
-          Apache, the Apache feather logo, Apache Isis, and the Apache Isis project logo are trademarks of The Apache Software Foundation.
+          Apache, the Apache feather logo, Apache&nbsp;Isis, and the Apache&nbsp;Isis project logo are all trademarks of The&nbsp;Apache&nbsp;Software&nbsp;Foundation.
           </p>
         </footer>
-      </div>
+
     </div>
-  </div>
-
-  
-    <script type="text/javascript">
-
-// Cache selectors
-var lastId,
-    topMenu = $("div#toc ul"),
-    topMenuHeight = 60,
-    // All list items
-    menuItems = topMenu.find("a"),
-    // Anchors corresponding to menu items
-    scrollItems = menuItems.map(function(){
-      var item = $($(this).attr("href"));
-      if (item.length) { return item; }
-    });
-
-// Bind click handler to menu items
-// so we can get a fancy scroll animation
-menuItems.click(function(e){
-  var href = $(this).attr("href"),
-      offsetTop = href === "#" ? 0 : $(href).offset().top-topMenuHeight+1;
-  $('html, body').stop().animate({ 
-      scrollTop: offsetTop
-  }, 300);
-  e.preventDefault();
-});
-
-// Bind to scroll
-$(  window ).scroll(function(){
-
-   // Get container scroll position
-   var fromTop = $(this).scrollTop()+topMenuHeight;
-  
-   //console.log("fromTop = " + fromTop);  
-   
-   // Get id of current scroll item
-   var cur = scrollItems.map(function(){
-     if ($(this).offset().top < fromTop)
-       return this;
-   });
-
-   // Get the id of the current element
-   cur = cur[cur.length-1];
-
-   //console.log("cur = " + cur);  
-
-   var id = cur && cur.length ? cur[0].id : "";
-
-   console.log("id = " + id + ", lastId = "  + lastId);  
-   
-   if (lastId !== id && id) {
-       lastId = id;
-       // Set/remove active class
-       menuItems
-         .removeClass("active");
-
-       menuItems
-         .parents()
-         .removeClass("active-region");
-         
-       menuItems
-         .parents("ul").hide();
-       
-       menuItems
-         .filter("[href=#"+id+"]")
-         .addClass("active");
-         
-       menuItems
-         .filter("[href=#"+id+"]")
-         .parents("ul").show();
-
-       menuItems
-         .filter("[href=#"+id+"]")
-         .parent().children("ul").show();
-
-       menuItems
-         .filter("[href=#"+id+"]")
-         .parents("li").addClass("active-region");
-
-     }                   
-});
-
-    </script>
-    </body>
+
+    <div class="large-4 medium-4 columns">
+        <!-- the 'hide' class is removed by Javascript -->
+        <div id="toc" class="<%= attr 'toc-class', 'toc2' %> hide">
+          <%= converter.convert_with_options @document, 'outline', :toclevels => 4  %>
+        </div>
+    </div>
+</div>
+
+
+    <script src="<%= (attr :_basedir) %>js/foundation/5.5.1/vendor/jquery.js"></script>
+    <script src="<%= (attr :_basedir) %>js/foundation/5.5.1/foundation.min.js"></script>
+
+
+<script type="text/javascript">
+      $(document).foundation();
+
+      $(document).ready(function(){
+        // Cache selectors
+        var lastId,
+            topMenu = $("div#toc ul"),
+            topMenuHeight = 70,
+
+            menuItems = topMenu.find("a"),
+            menuItemsHrefs = menuItems.map(function(){
+              var item = $($(this).attr("href"));
+              if (item.length) { return item; }
+            });
+
+        // Bind click handler to menu items to scroll animation
+        menuItems.click(function(e){
+          var href = $(this).attr("href"),
+              offsetTop = href === "#" ? 0 : $(href).offset().top-topMenuHeight+1;
+          $('html, body').stop().animate({
+              scrollTop: offsetTop
+          }, 300);
+
+          e.preventDefault();
+        });
+
+        // Bind to scroll of window
+        $(  window ).scroll(function(){
+
+           // Get container scroll position
+           var fromTop = $(this).scrollTop()+topMenuHeight;
+
+           var cur = menuItemsHrefs.map(function(){
+             if ($(this).offset().top < fromTop)
+               return this;
+           });
+
+           // Get the id of the current element
+           cur = cur[cur.length-1];
+
+           var id = cur && cur.length ? cur[0].id : "";
+
+           //console.log("id = " + id + ", lastId = "  + lastId);
+
+           if (lastId !== id && id) {
+               scrollTo(id);
+           }
+        });
+
+        scrollTo = function(id) {
+              lastId = id;
+
+              menuItems
+                .removeClass("active");
+
+              menuItems
+                .parents()
+                .removeClass("active-region");
+
+              menuItems
+                .parents("ul").hide();
+
+              menuItems
+                .filter("[href=#"+id+"]")
+                .addClass("active");
+
+              menuItems
+                .filter("[href=#"+id+"]")
+                .parents("ul").show();
+
+              menuItems
+                .filter("[href=#"+id+"]")
+                .parent().children("ul").show();
+
+              menuItems
+                .filter("[href=#"+id+"]")
+                .parents("li").addClass("active-region");
+
+        }
+      menuItems
+        .removeClass("active");
+
+      menuItems
+        .parents()
+        .removeClass("active-region");
+
+        var syncMenuItem;
+        if(window.location.hash!=="") {
+            var menuItemFor = $.grep(menuItems, function(e) {
+                return e.hash === window.location.hash;
+            });
+            console.log(menuItemFor);
+            if(menuItemFor.length === 1) {
+                syncMenuItem = menuItemFor[0];
+            }
+        }
+
+        if(!syncMenuItem){
+            syncMenuItem = menuItems[0];
+        }
+
+        $("#toc").removeClass("hide");
+
+        $(syncMenuItem).click();
+
+      });
+
+
+</script>
+
+
+</body>
 </html>