Skip to content
Merged
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 14 additions & 4 deletions src/components/entity/state-info.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { html } from "@polymer/polymer/lib/utils/html-tag";
import "@polymer/paper-tooltip/paper-tooltip";
/* eslint-plugin-disable lit */
import { PolymerElement } from "@polymer/polymer/polymer-element";
import { computeStateName } from "../../common/entity/compute_state_name";
Expand Down Expand Up @@ -74,10 +75,19 @@ class StateInfo extends PolymerElement {

<template is="dom-if" if="[[inDialog]]">
<div class="time-ago">
<ha-relative-time
hass="[[hass]]"
datetime="[[stateObj.last_changed]]"
></ha-relative-time>
<span>
Comment thread
pszafer marked this conversation as resolved.
Outdated
<ha-relative-time
hass="[[hass]]"
datetime="[[stateObj.last_changed]]"
></ha-relative-time>
<paper-tooltip animation-delay="0">
[[localize('ui.dialogs.more_info_control.last_updated')]]:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This string doesn't exist yet? You have to add it to src/translations/en.json

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added. one notice, even if string is added it doesn't show in my browser. Actually it doesn't show even if I use some other string like ui.dialogs.more_info_control.dismiss.

<ha-relative-time
hass="[[hass]]"
datetime="[[stateObj.last_updated]]"
></ha-relative-time>
</paper-tooltip>
</span>
</div>
</template>
<template is="dom-if" if="[[!inDialog]]">
Expand Down