@websolutespa/bom-llm 0.0.53 → 0.0.55

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
@@ -1,5 +1,17 @@
1
1
  # @websolutespa/bom-llm
2
2
 
3
+ ## 0.0.55
4
+
5
+ ### Patch Changes
6
+
7
+ - Added: disclaimerShort, Disclaimer, Scroller image-mask
8
+
9
+ ## 0.0.54
10
+
11
+ ### Patch Changes
12
+
13
+ - Added: ScrollProposition, imperative flag
14
+
3
15
  ## 0.0.53
4
16
 
5
17
  ### Patch Changes
package/README.md CHANGED
@@ -74,6 +74,11 @@ document.addEventListener('DOMContentLoaded', () => {
74
74
  Using imperatively.
75
75
 
76
76
  ```js
77
+ const options = {
78
+ appKey: 'MY_APP_KEY',
79
+ apiKey: 'MY_API_KEY',
80
+ imperative: true, // hide trigger button
81
+ };
77
82
  const llm = bomLlm(options);
78
83
  // using open command imperatively
79
84
  setTimeout(() => {
package/dist/index.d.ts CHANGED
@@ -49,6 +49,7 @@ type LlmContents = {
49
49
  disableSpeechRecognition?: boolean;
50
50
  disableSpeechSynthesis?: boolean;
51
51
  disclaimer?: string;
52
+ disclaimerShort?: string;
52
53
  disclaimerFooter?: boolean;
53
54
  enableUpload?: boolean;
54
55
  extendedWelcomeText?: string;
@@ -90,6 +91,7 @@ type LlmViewOptions = {
90
91
  preview?: boolean;
91
92
  opened?: boolean;
92
93
  dismissable?: boolean;
94
+ imperative?: boolean;
93
95
  skipCustomIntro?: boolean;
94
96
  embedded?: boolean;
95
97
  };
@@ -1184,6 +1184,7 @@ llm-embed {
1184
1184
  overflow-x: hidden;
1185
1185
  overflow-y: auto;
1186
1186
  max-width: 100%;
1187
+ mask-image: linear-gradient(to bottom, black calc(100% - 240px), transparent calc(100% - 60px));
1187
1188
  /*
1188
1189
  &.lenis.lenis-stopped {
1189
1190
  overflow-x: hidden;
@@ -1966,6 +1967,68 @@ llm-embed {
1966
1967
  color: var(--llm-color-foreground);
1967
1968
  opacity: 0.8;
1968
1969
  }
1970
+ .llm .llm__prompt-disclaimer button {
1971
+ margin: 0;
1972
+ padding: 0;
1973
+ border: none;
1974
+ text-decoration: none;
1975
+ background: none;
1976
+ appearance: none;
1977
+ font-family: inherit;
1978
+ font-style: inherit;
1979
+ font-variant-ligatures: inherit;
1980
+ font-variant-caps: inherit;
1981
+ font-variant-numeric: inherit;
1982
+ font-variant-east-asian: inherit;
1983
+ font-weight: inherit;
1984
+ font-stretch: inherit;
1985
+ text-rendering: inherit;
1986
+ letter-spacing: inherit;
1987
+ word-spacing: inherit;
1988
+ line-height: inherit;
1989
+ text-transform: none;
1990
+ text-indent: inherit;
1991
+ text-shadow: none;
1992
+ text-align: inherit;
1993
+ pointer-events: auto;
1994
+ cursor: pointer;
1995
+ outline: 2px solid transparent;
1996
+ outline-offset: 2px;
1997
+ text-decoration: underline;
1998
+ }
1999
+ .llm .llm__prompt-disclaimer button:focus, .llm .llm__prompt-disclaimer button:focus-visible {
2000
+ outline-color: var(--llm-color-outline);
2001
+ }
2002
+ .llm .llm__prompt-disclaimer button:hover {
2003
+ outline-color: color-mix(in srgb, var(--llm-color-outline) 10%, transparent 90%);
2004
+ }
2005
+ .llm .llm__prompt-disclaimer button:active {
2006
+ outline-color: var(--llm-color-accent-foreground);
2007
+ }
2008
+ .llm .llm__prompt-disclaimer__long {
2009
+ position: fixed;
2010
+ top: 50%;
2011
+ left: 50%;
2012
+ transform: translateX(-50%) translateY(-50%);
2013
+ font-size: 14px;
2014
+ line-height: 1.4;
2015
+ padding: var(--llm-size-2, 1rem) var(--llm-size-3, 1.5rem);
2016
+ width: calc(100vw - var(--rem, 1rem) * 2);
2017
+ max-width: 600px;
2018
+ border-radius: 12px;
2019
+ background: var(--llm-popup-background);
2020
+ color: var(--llm-popup-foreground);
2021
+ border: var(--llm-popup-border, none);
2022
+ box-shadow: var(--llm-trigger-box-shadow);
2023
+ transition: 0.4s;
2024
+ pointer-events: auto;
2025
+ }
2026
+ .llm .llm__prompt-disclaimer__long a {
2027
+ text-decoration: underline;
2028
+ }
2029
+ .llm .llm__prompt-disclaimer__long a:link, .llm .llm__prompt-disclaimer__long a:active, .llm .llm__prompt-disclaimer__long a:visited, .llm .llm__prompt-disclaimer__long a:hover {
2030
+ color: var(--llm-pill-foreground);
2031
+ }
1969
2032
  @media (min-width: 1024px) {
1970
2033
  .llm .llm__prompt-disclaimer {
1971
2034
  font-size: 11px;
@@ -4281,6 +4344,30 @@ llm-embed {
4281
4344
  left: -1px;
4282
4345
  }
4283
4346
 
4347
+ .llm .llm__scroll-proposition {
4348
+ position: absolute;
4349
+ display: flex;
4350
+ justify-content: center;
4351
+ align-items: center;
4352
+ top: -50px;
4353
+ left: 50%;
4354
+ width: var(--llm-scroll-proposition-size);
4355
+ height: var(--llm-scroll-proposition-size);
4356
+ border-radius: var(--llm-scroll-proposition-border-radius);
4357
+ font-size: var(--llm-scroll-proposition-border-radius);
4358
+ z-index: 1000;
4359
+ transform: translateX(-50%);
4360
+ background: var(--llm-scroll-proposition-background);
4361
+ color: var(--llm-scroll-proposition-foreground);
4362
+ box-shadow: var(--llm-scroll-proposition-box-shadow);
4363
+ cursor: pointer;
4364
+ }
4365
+ .llm .llm__scroll-proposition svg {
4366
+ width: var(--llm-scroll-proposition-border-radius);
4367
+ height: var(--llm-scroll-proposition-border-radius);
4368
+ transform: rotate(90deg);
4369
+ }
4370
+
4284
4371
  /**
4285
4372
  * Swiper 8.4.7
4286
4373
  * Most modern mobile touch slider and framework with hardware accelerated transitions