@empathyco/x-components 3.0.0-alpha.86 → 3.0.0-alpha.87

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,23 @@
3
3
  All notable changes to this project will be documented in this file. See
4
4
  [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [3.0.0-alpha.87](https://github.com/empathyco/x/compare/@empathyco/x-components@3.0.0-alpha.86...@empathyco/x-components@3.0.0-alpha.87) (2022-04-26)
7
+
8
+ ### Features
9
+
10
+ - **extra-params:** makes `excludedExtraParams` configurable
11
+ ([ca2bed1](https://github.com/empathyco/x/commit/ca2bed17c7ef8ed893a65e7d1a055901491ea8fa))
12
+
13
+ ### Documentation
14
+
15
+ - review build search UI docs
16
+ ([fc72ad7](https://github.com/empathyco/x/commit/fc72ad78fbff0deaa2f1a417c8e7f005ea2c8470))
17
+
18
+ # Change Log
19
+
20
+ All notable changes to this project will be documented in this file. See
21
+ [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
22
+
6
23
  ## [3.0.0-alpha.86](https://github.com/empathyco/x/compare/@empathyco/x-components@3.0.0-alpha.85...@empathyco/x-components@3.0.0-alpha.86) (2022-04-19)
7
24
 
8
25
  ### Features
@@ -2725,6 +2725,27 @@
2725
2725
  .x-message > p {
2726
2726
  margin: 0;
2727
2727
  }
2728
+ :root {
2729
+ --x-string-justify-message-default: center;
2730
+ --x-size-gap-message-default: var(--x-size-base-03);
2731
+ --x-size-padding-message-default: var(--x-size-base-06);
2732
+ --x-color-background-message-default: var(--x-color-base-neutral-95);
2733
+ --x-color-border-message-default: var(--x-color-background-message-default);
2734
+ --x-color-text-message-default: var(--x-color-text-default);
2735
+ --x-size-border-radius-message-default: var(--x-size-border-radius-base-m);
2736
+ --x-size-border-radius-top-left-message-default: var(--x-size-border-radius-message-default);
2737
+ --x-size-border-radius-top-right-message-default: var(--x-size-border-radius-message-default);
2738
+ --x-size-border-radius-bottom-right-message-default: var(--x-size-border-radius-message-default);
2739
+ --x-size-border-radius-bottom-left-message-default: var(--x-size-border-radius-message-default);
2740
+ --x-size-border-width-message-default: var(--x-size-border-width-base);
2741
+ --x-size-border-width-top-message-default: var(--x-size-border-width-message-default);
2742
+ --x-size-border-width-right-message-default: var(--x-size-border-width-message-default);
2743
+ --x-size-border-width-bottom-message-default: var(--x-size-border-width-message-default);
2744
+ --x-size-border-width-left-message-default: var(--x-size-border-width-message-default);
2745
+ --x-font-family-message-default: var(--x-font-family-title3);
2746
+ --x-size-font-message-default: var(--x-size-font-title3);
2747
+ --x-number-font-weight-message-default: var(--x-number-font-weight-title3);
2748
+ }
2728
2749
  .x-option-list--bottom.x-option-list,
2729
2750
  .x-option-list--bottom .x-option-list {
2730
2751
  --x-color-text-option-list-button-default: var(--x-color-text-option-list-button-bottom);
@@ -3256,23 +3277,6 @@
3256
3277
  opacity: 1;
3257
3278
  }
3258
3279
  }
3259
- :root {
3260
- --x-color-border-result-default: var(--x-color-base-lead);
3261
- --x-color-border-result-picture-default: var(--x-color-border-result-default);
3262
- --x-color-border-result-overlay-default: var(--x-color-border-result-default);
3263
- --x-color-border-result-description-default: var(--x-color-border-result-default);
3264
- --x-color-background-result-default: transparent;
3265
- --x-size-padding-result-default: 0;
3266
- --x-size-padding-result-picture-default: 0;
3267
- --x-size-padding-result-overlay-default: 0;
3268
- --x-size-padding-result-description-default: 0;
3269
- --x-size-gap-result-default: var(--x-size-base-03);
3270
- --x-size-border-radius-result-default: var(--x-size-border-radius-base-none);
3271
- --x-size-border-width-result-default: 0;
3272
- --x-size-border-width-result-picture-default: 0;
3273
- --x-size-border-width-result-overlay-default: 0;
3274
- --x-size-border-width-result-description-default: 0;
3275
- }
3276
3280
  .x-row {
3277
3281
  display: grid;
3278
3282
  grid-template-columns: repeat(12, 1fr);
@@ -7547,23 +7551,19 @@
7547
7551
  }
7548
7552
 
7549
7553
  :root {
7550
- --x-string-justify-message-default: center;
7551
- --x-size-gap-message-default: var(--x-size-base-03);
7552
- --x-size-padding-message-default: var(--x-size-base-06);
7553
- --x-color-background-message-default: var(--x-color-base-neutral-95);
7554
- --x-color-border-message-default: var(--x-color-background-message-default);
7555
- --x-color-text-message-default: var(--x-color-text-default);
7556
- --x-size-border-radius-message-default: var(--x-size-border-radius-base-m);
7557
- --x-size-border-radius-top-left-message-default: var(--x-size-border-radius-message-default);
7558
- --x-size-border-radius-top-right-message-default: var(--x-size-border-radius-message-default);
7559
- --x-size-border-radius-bottom-right-message-default: var(--x-size-border-radius-message-default);
7560
- --x-size-border-radius-bottom-left-message-default: var(--x-size-border-radius-message-default);
7561
- --x-size-border-width-message-default: var(--x-size-border-width-base);
7562
- --x-size-border-width-top-message-default: var(--x-size-border-width-message-default);
7563
- --x-size-border-width-right-message-default: var(--x-size-border-width-message-default);
7564
- --x-size-border-width-bottom-message-default: var(--x-size-border-width-message-default);
7565
- --x-size-border-width-left-message-default: var(--x-size-border-width-message-default);
7566
- --x-font-family-message-default: var(--x-font-family-title3);
7567
- --x-size-font-message-default: var(--x-size-font-title3);
7568
- --x-number-font-weight-message-default: var(--x-number-font-weight-title3);
7554
+ --x-color-border-result-default: var(--x-color-base-lead);
7555
+ --x-color-border-result-picture-default: var(--x-color-border-result-default);
7556
+ --x-color-border-result-overlay-default: var(--x-color-border-result-default);
7557
+ --x-color-border-result-description-default: var(--x-color-border-result-default);
7558
+ --x-color-background-result-default: transparent;
7559
+ --x-size-padding-result-default: 0;
7560
+ --x-size-padding-result-picture-default: 0;
7561
+ --x-size-padding-result-overlay-default: 0;
7562
+ --x-size-padding-result-description-default: 0;
7563
+ --x-size-gap-result-default: var(--x-size-base-03);
7564
+ --x-size-border-radius-result-default: var(--x-size-border-radius-base-none);
7565
+ --x-size-border-width-result-default: 0;
7566
+ --x-size-border-width-result-picture-default: 0;
7567
+ --x-size-border-width-result-overlay-default: 0;
7568
+ --x-size-border-width-result-description-default: 0;
7569
7569
  }
@@ -0,0 +1,13 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@empathyco/x-components](./x-components.md) &gt; [SnippetConfigExtraParams](./x-components.snippetconfigextraparams.md) &gt; [excludedExtraParams](./x-components.snippetconfigextraparams.excludedextraparams.md)
4
+
5
+ ## SnippetConfigExtraParams.excludedExtraParams property
6
+
7
+ Collection of properties from the snippet config to exclude from the extra params object.
8
+
9
+ <b>Signature:</b>
10
+
11
+ ```typescript
12
+ protected excludedExtraParams: Array<keyof SnippetConfig>;
13
+ ```
@@ -17,5 +17,6 @@ export default class SnippetConfigExtraParams extends Vue
17
17
 
18
18
  | Property | Modifiers | Type | Description |
19
19
  | --- | --- | --- | --- |
20
+ | [excludedExtraParams](./x-components.snippetconfigextraparams.excludedextraparams.md) | | Array&lt;keyof [SnippetConfig](./x-components.snippetconfig.md)<!-- -->&gt; | Collection of properties from the snippet config to exclude from the extra params object. |
20
21
  | [values?](./x-components.snippetconfigextraparams.values.md) | | Dictionary&lt;unknown&gt; | <i>(Optional)</i> A Dictionary where the keys are the extra param names and its values. |
21
22
 
@@ -11,9 +11,10 @@ objects of every x-module.
11
11
 
12
12
  ## Props
13
13
 
14
- | Name | Description | Type | Default |
15
- | ------------------- | --------------------------------------------------------------------- | ----------------------- | ------------- |
16
- | <code>values</code> | A Dictionary where the keys are the extra param names and its values. | <code>Dictionary</code> | <code></code> |
14
+ | Name | Description | Type | Default |
15
+ | -------------------------------- | ---------------------------------------------------------------------------------------------- | ----------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
16
+ | <code>values</code> | A Dictionary where the keys are the extra param names and its values. | <code>Dictionary</code> | <code></code> |
17
+ | <code>excludedExtraParams</code> | Collection of properties from the snippet config to exclude from the<br />extra params object. | <code>Array</code> | <code>(): Array<keyof SnippetConfig> => [<br /> 'callbacks',<br /> 'productId',<br /> 'instance',<br /> 'lang',<br /> 'searchLang',<br /> 'consent',<br /> 'documentDirection',<br /> 'currency'<br />]</code> |
17
18
 
18
19
  ## See it in action
19
20
 
@@ -6,13 +6,15 @@ tags:
6
6
  - use x components
7
7
  - x components
8
8
  - interface x
9
+ - x archetype
10
+ - archetype
9
11
  ---
10
12
 
11
13
  ::: slot left-intro-column
12
14
 
13
- ## Getting started with Interface X Components
15
+ ## Getting started with Interface X
14
16
 
15
- Start building your search and discovery experience in a few simple steps:
17
+ Start building your search and discovery experience:
16
18
 
17
19
  :::
18
20
 
@@ -22,12 +24,12 @@ Start building your search and discovery experience in a few simple steps:
22
24
 
23
25
  :::
24
26
 
25
- - **Discover more about the [Interface X ecosystem](#the-interface-x-ecosystem)** and how
26
- Interface&nbsp;X works.
27
+ - **Discover the [Interface X ecosystem](#the-interface-x-ecosystem)** and how Interface&nbsp;X
28
+ works.
29
+ - **[Develop using Interface X](#develop-with-interface-x)** inside your project.
27
30
  - **[Integrate the Interface X Archetype](#integrate-interface-x-archetype)** in your store web
28
31
  application.
29
- - **[Develop using the Interface X](#develop-with-interface-x)** inside your current project.
30
- - **[How to use and configure the Interface X Components](#how-to-use-and-configure-the-interface-x-components)**
32
+ - **[Use and configure the Interface X Components](#use-and-configure-the-interface-x-components)**
31
33
  in your project.
32
34
 
33
35
  <!-- 3. Style your UI. 4. Translate your search experience-->
@@ -43,25 +45,15 @@ numerous components to choose from, and the catalog evolves quickly with new exp
43
45
  Check out the **[open source project in GitHub](https://github.com/empathyco/x)**.
44
46
 
45
47
  Interested in learning more about how Interface&nbsp;X works? Discover more about its
46
- **[architecture](x-architecture/README.md)**.
47
-
48
- ## Integrate Interface X Archetype
49
-
50
- Once you have finished developing or extending your search interface using the
51
- Interface&nbsp;X&nbsp;Archetype project you will probably want to integrate it into your current
52
- store. The integration of an existing Archetype into your project is pretty straightforward. You
53
- will need to load the generated Javascript into your website and initialise it.
54
-
55
- To start integrating an existent Archetype into your project please visit
56
- [extended guide about Archetype integration](web-archetype-integration-guide.md).
48
+ **[architecture](web-x-architecture.md)**.
57
49
 
58
50
  ## Develop with Interface X
59
51
 
60
- You can use the Interface X in a project in two ways:
52
+ You can use the Interface&nbsp;X in a project in two ways:
61
53
 
62
54
  - using the separate **Interface&nbsp;X&nbsp;Archetype** project, an out-of-the-box project with all
63
- you need to get up and running fast, or
64
- - integrating the individual **Interface&nbsp;X&nbsp;Components** library in your Vue project for a
55
+ you need to get up and running fast
56
+ - importing the individual **Interface&nbsp;X&nbsp;Components** library in your Vue project for a
65
57
  more custom approach.
66
58
 
67
59
  ::: note
@@ -73,9 +65,9 @@ You can use Empathy Search API, Elasticsearch, or Solr endpoints with both appro
73
65
  ##### Develop via Interface X Archetype
74
66
 
75
67
  The **[Interface&nbsp;X&nbsp;Archetype](https://github.com/empathyco/x-archetype)** project is the
76
- perfect combination of all the existing X&nbsp;Components. Instead of starting from a completely
77
- blank canvas, ramp up quickly with an already working search and discovery experience. This is the
78
- perfect solution for most cases. But don’t worry! It’s still super flexible! You’re still able to:
68
+ perfect combination of all the existing X&nbsp;Components. It allows you to ramp up quickly with an
69
+ already working search and discovery experience, instead of starting from a completely blank canvas.
70
+ This is the perfect solution for most cases as you can use it as a springboard to:
79
71
 
80
72
  - Change the default styles for styles that match your application through design tokens or custom
81
73
  CSS.
@@ -86,33 +78,46 @@ perfect solution for most cases. But don’t worry! It’s still super flexible!
86
78
  - Create new components or modify the existing ones.
87
79
 
88
80
  To start developing the X&nbsp;Archetype project, see
89
- **[Develop via Interface X Archetype](web-archetype-development-guide.md)**.
81
+ **[Develop using Interface&nbsp;X&nbsp;Archetype](web-archetype-development-guide.md)**.
90
82
 
91
83
  ##### Develop via Interface X Components library
92
84
 
93
85
  This is the more deep and flexible use of the
94
- **[Interface X Components library](https://github.com/empathyco/x/tree/main/packages/x-components)**,
86
+ **[Interface&nbsp;X&nbsp;Components library](https://github.com/empathyco/x/tree/main/packages/x-components)**,
95
87
  allowing you to import any components you desire into your Vue application. It lets you connect,
96
88
  customize, extend, style, or even create new components without any limitations. This is the way to
97
- go if you like to look under the hood!
89
+ go if you like to look under the hood.
98
90
 
99
91
  - Mix and match with other Vue components.
100
92
  - Implement in Vue or React projects.
101
93
  - Extend component behavior with your own development.
102
94
  - Determine styles using design tokens or custom CSS.
103
95
 
104
- To get started with the X Components library, check out
105
- **[Develop using Interface X Components library](web-x-components-integration-guide.md)**.
96
+ To get started with the X&nbsp;Components library, check out
97
+ **[Develop using Interface&nbsp;X&nbsp;Components library](web-x-components-development-guide.md)**.
98
+
99
+ ## Integrate Interface X Archetype
100
+
101
+ With the **[Interface&nbsp;X&nbsp;Archetype](https://github.com/empathyco/x-archetype)** you have an
102
+ isolated search layer up and running in your store web application in a matter of minutes.
103
+
104
+ To integrate the Interface&nbsp;X&nbsp;Archetype into your project, just **load** the generated
105
+ JavaScript file into your website and **initialize** it.
106
+
107
+ Check out
108
+ **[Integrate InterfaceX&nbsp;Archetype into an existing website](web-archetype-integration-guide.md)**,
109
+ to integrate the X&nbsp;Archetype project.
110
+
111
+ ## Use and configure the Interface X Components
106
112
 
107
- ## How to use and configure the Interface X Components
113
+ To use the Interface&nbsp;X&nbsp;Components, just **import** and **register** the component,
114
+ **include** it in your template, and you’re ready to go.
108
115
 
109
- Using the Interface&nbsp;X&nbsp;Components is a piece of cake! Just import and register the
110
- component, include it in your template, and you’re ready to go! What’s more, each component offers
111
- multiple configuration parameters to play around with, allowing you greater flexibility over the
112
- experience.
116
+ What’s more, each component offers multiple configuration parameters to play around with, giving you
117
+ greater flexibility over the experience.
113
118
 
114
119
  Unsure how to start? Check out
115
- **[How to use & configure Interface X Components in your project](web-how-to-use-x-components-guide.md)**.
120
+ **[How to use and configure Interface&nbsp;X&nbsp;Components in your project](web-how-to-use-x-components-guide.md)**.
116
121
 
117
122
  <!--
118
123
  ## Style your UI
@@ -1,30 +1,26 @@
1
1
  ---
2
- title: Interface X Archetype Development
2
+ title: Develop using Interface X Archetype
3
3
  tags:
4
4
  - development
5
5
  - archetype
6
- - X Components archetype development
6
+ - X archetype development
7
7
  - x development
8
8
  - interface x
9
9
  - x components
10
10
  - archetype development
11
- - archetype integration
12
11
  ---
13
12
 
14
- # Interface X Archetype Development
13
+ # Develop using Interface X Archetype
15
14
 
16
- In this tutorial, you’ll learn how to start developing with the Interface&nbsp;X&nbsp;Archetype
17
- project in your store in a matter of minutes, so you can create a search interface layer based on
18
- predefined features and components.
15
+ In this tutorial, you’ll learn how to build a search and discovery layer based on predefined
16
+ features and components in a matter of minutes using the Interface&nbsp;X&nbsp;Archetype.
19
17
 
20
18
  For this tutorial, the Empathy Search API is used, but you can use any search API. This guide
21
19
  requires knowledge of JavaScript and Vue.js.
22
20
 
23
21
  ::: note Before you begin
24
22
 
25
- To integrate Interface&nbsp;X&nbsp;Archetype as a search UI layer, you need:
26
-
27
- <br/>
23
+ To use Interface&nbsp;X&nbsp;Archetype as a search UI layer, you need:
28
24
 
29
25
  - **Empathy Search API** (or any search API that you use to retrieve search data).
30
26
  - **Empathy Search Adapter** to communicate with the Empathy Search API (or any search adapter to
@@ -32,10 +28,10 @@ To integrate Interface&nbsp;X&nbsp;Archetype as a search UI layer, you need:
32
28
 
33
29
  :::
34
30
 
35
- ##### Steps to start developing in a X Archetype project:
31
+ ##### Steps to build a search layer using the X Archetype project:
36
32
 
37
33
  1. **Clone** the X&nbsp;Archetype project and **initialize** your repository.
38
- 2. Install the **project dependencies** and execute the project.
34
+ 2. Install the **project dependencies** and run the project development server.
39
35
  3. Configure the **search adapter**.
40
36
  4. Configure the **xPlugin**.
41
37
 
@@ -109,8 +105,8 @@ Interface&nbsp;X&nbsp;Archetype repository.
109
105
  Before using your project, configure the Empathy Search Adapter in the
110
106
  `x-archetype/src/adapter/adapter.ts` file, using the Empathy Adapter Builder to make it work with
111
107
  the Empathy Search API. The Empathy Search Adapter contains a sample configuration for setup, global
112
- configurations, or mappers that points to a demo environment. You need to make some adjustments in
113
- the configuration according to the search features you use in your project.
108
+ configurations, or mappers that points to a demo environment. You need to adjust the configuration
109
+ according to the search features you use in your project.
114
110
 
115
111
  Export the required search adapter with your configuration as you will need it for the search
116
112
  [xPlugin configuration](#4-configure-the-plugin).
@@ -126,13 +122,18 @@ For detailed information about other configuration options in the Empathy Search
126
122
 
127
123
  Although you configure the values for the `instance`, `language`, `scope`, and `endpoint` options
128
124
  when integrating the project, you can still change these values when the project is deployed. Use
129
- the `/x-archetype/public/snippet-script.js` file to perform hot changes for `lang`, `store`,
130
- `device`, and `catalog` parameters.
125
+ the `/x-archetype/public/snippet-script.js` file to initialize values for `lang`, `store`, `device`,
126
+ and `catalog` parameters.
131
127
 
132
128
  For example, you may configure the adapter to use EN as `lang` so that when you search, the results
133
129
  are displayed in English. However, if you want to deploy the application in Spain, you want the
134
130
  `lang` to be ES. You change these values in the `snippet-script.js` file.
135
131
 
132
+ </br>
133
+
134
+ For detailed information, see
135
+ [Snippet configuration](web-archetype-integration-guide.md#snippet-configuration)
136
+
136
137
  :::
137
138
 
138
139
  ## 4. Configure the plugin
@@ -167,21 +168,21 @@ new XInstaller(installXOptions).init({
167
168
  });
168
169
  ```
169
170
 
170
- ---
171
+ ::: develop Next steps
171
172
 
172
- ### Next steps
173
+ Once you have your Interface&nbsp;X&nbsp;Archetype project, you're ready to **integrate** it in your
174
+ store or **extend** the search and discovery experience to meet your business needs:
173
175
 
174
- Once you have your Interface&nbsp;X&nbsp;Archetype project, you're ready to integrate it in your
175
- store, or extend the search and discovery experience to meet your business needs:
176
-
177
- - [Integrate an Interface&nbsp;X&nbsp;Archetype project into an existing website](web-archetype-integration-guide.md).
178
- - Change the configuration of [X Components](web-how-to-use-x-components-guide.md) or create new
179
- ones.
176
+ - [**Integrate an Interface&nbsp;X&nbsp;Archetype project** into an existing website](web-archetype-integration-guide.md).
177
+ - Change the **configuration of [X&nbsp;Components](web-how-to-use-x-components-guide.md)** or
178
+ create new ones.
180
179
  - Adapt the
181
- [design system](https://github.com/empathyco/x/blob/main/packages/x-components/contributing/design-system.md)
180
+ **[design system](https://github.com/empathyco/x/blob/main/packages/x-components/contributing/design-system.md)**
182
181
  to your branding.
183
182
  - Manage
184
- [internationalization options](https://github.com/empathyco/x-archetype/blob/main/docs/i18n.md) to
185
- support different languages.
183
+ **[internationalization options](https://github.com/empathyco/x-archetype/blob/main/docs/i18n.md)**
184
+ to support different languages.
185
+
186
+ :::
186
187
 
187
188
  <!-- add links to design system and internationalization content pages when ready-->